@hep-code-runner/vue2 2.3.6 → 2.3.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});var ee=Object.defineProperty,Z=(e,t,i)=>((c,p,f)=>p in c?ee(c,p,{enumerable:!0,configurable:!0,writable:!0,value:f}):c[p]=f)(e,typeof t!="symbol"?t+"":t,i);let H=null;class te{constructor(t={}){Z(this,"baseUrl"),Z(this,"timeout"),this.baseUrl=t.pistonUrl||"/api/piston",this.timeout=t.timeout||3e3}async getRuntimes(t=!1){if(H&&!t)return H;try{const i=await fetch(`${this.baseUrl}/runtimes`,{method:"GET",headers:{"Content-Type":"application/json"}});if(!i.ok)throw new Error(`Failed to fetch runtimes: ${i.statusText}`);const c=await i.json();return H=c,c}catch(i){throw i}}async execute(t,i,c={}){const p=(await this.getRuntimes()).find(h=>{var m;return h.language.toLowerCase()===t.toLowerCase()||((m=h.aliases)==null?void 0:m.some(k=>k.toLowerCase()===t.toLowerCase()))});if(!p)throw new Error(`Language '${t}' is not supported`);const f=this.getFileName(t),l={language:p.language,version:c.version||p.version,files:[{name:f,content:i}],stdin:c.stdin||"",args:c.args||[],run_timeout:c.runTimeout||this.timeout,compile_timeout:this.timeout},b=Date.now();try{const h=await fetch(`${this.baseUrl}/execute`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(l)});if(!h.ok)throw new Error(`Execute failed: ${h.statusText}`);const m=await h.json(),k=Date.now()-b,S=m.run.stdout||"",T=m.run.stderr||"";return{success:m.run.code===0,output:S,stderr:T,code:m.run.code,executionTime:k,compile:m.compile?{stdout:m.compile.stdout||"",stderr:m.compile.stderr||"",code:m.compile.code}:void 0}}catch(h){return{success:!1,output:"",stderr:h instanceof Error?h.message:"Unknown error",code:-1,executionTime:Date.now()-b}}}getFileName(t){return{javascript:"main.js",typescript:"main.ts",python:"main.py",python3:"main.py",go:"main.go",rust:"main.rs",java:"Main.java",c:"main.c",cpp:"main.cpp",csharp:"Main.cs",ruby:"main.rb",php:"main.php",bash:"main.sh",shell:"main.sh",perl:"main.pl",lua:"main.lua",swift:"main.swift",kotlin:"Main.kt",scala:"Main.scala",haskell:"main.hs",dart:"main.dart",html:"index.html",css:"style.css",sql:"query.sql",markdown:"readme.md"}[t.toLowerCase()]||`main.${t}`}}const ne={javascript:'console.log("Hello, World!");',typescript:'console.log("Hello, World!");',python:'print("Hello, World!")',python3:'print("Hello, World!")',go:`package main
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});var ee=Object.defineProperty,B=(e,t,i)=>((c,p,f)=>p in c?ee(c,p,{enumerable:!0,configurable:!0,writable:!0,value:f}):c[p]=f)(e,typeof t!="symbol"?t+"":t,i);let j=null;class te{constructor(t={}){B(this,"baseUrl"),B(this,"timeout"),B(this,"token"),this.baseUrl=t.pistonUrl||"/api/piston",this.timeout=t.timeout||3e3,this.token=t.token}authHeaders(){const t={"Content-Type":"application/json"};return this.token&&(t.authorization=`Bearer ${this.token}`,t["id-token"]=this.token),t}async getRuntimes(t=!1){if(j&&!t)return j;try{const i=await fetch(`${this.baseUrl}/runtimes`,{method:"GET",headers:this.authHeaders()});if(!i.ok)throw new Error(`Failed to fetch runtimes: ${i.statusText}`);const c=await i.json();return j=c,c}catch(i){throw i}}async execute(t,i,c={}){const p=(await this.getRuntimes()).find(h=>{var m;return h.language.toLowerCase()===t.toLowerCase()||((m=h.aliases)==null?void 0:m.some(k=>k.toLowerCase()===t.toLowerCase()))});if(!p)throw new Error(`Language '${t}' is not supported`);const f=this.getFileName(t),l={language:p.language,version:c.version||p.version,files:[{name:f,content:i}],stdin:c.stdin||"",args:c.args||[],run_timeout:c.runTimeout||this.timeout,compile_timeout:this.timeout},b=Date.now();try{const h=await fetch(`${this.baseUrl}/execute`,{method:"POST",headers:this.authHeaders(),body:JSON.stringify(l)});if(!h.ok)throw new Error(`Execute failed: ${h.statusText}`);const m=await h.json(),k=Date.now()-b,S=m.run.stdout||"",T=m.run.stderr||"";return{success:m.run.code===0,output:S,stderr:T,code:m.run.code,executionTime:k,compile:m.compile?{stdout:m.compile.stdout||"",stderr:m.compile.stderr||"",code:m.compile.code}:void 0}}catch(h){return{success:!1,output:"",stderr:h instanceof Error?h.message:"Unknown error",code:-1,executionTime:Date.now()-b}}}getFileName(t){return{javascript:"main.js",typescript:"main.ts",python:"main.py",python3:"main.py",go:"main.go",rust:"main.rs",java:"Main.java",c:"main.c",cpp:"main.cpp",csharp:"Main.cs",ruby:"main.rb",php:"main.php",bash:"main.sh",shell:"main.sh",perl:"main.pl",lua:"main.lua",swift:"main.swift",kotlin:"Main.kt",scala:"Main.scala",haskell:"main.hs",dart:"main.dart",html:"index.html",css:"style.css",sql:"query.sql",markdown:"readme.md"}[t.toLowerCase()]||`main.${t}`}}const ne={javascript:'console.log("Hello, World!");',typescript:'console.log("Hello, World!");',python:'print("Hello, World!")',python3:'print("Hello, World!")',go:`package main
2
2
 
3
3
  import "fmt"
4
4
 
@@ -63,8 +63,8 @@ h1 {
63
63
  color: #333;
64
64
  }`,sql:"SELECT 'Hello, World!' AS message;",markdown:`# Hello, World!
65
65
 
66
- This is a sample markdown document.`};var K=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ae(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var V={exports:{}};(function(e){var t=function(i){var c=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,p=0,f={},l={manual:i.Prism&&i.Prism.manual,disableWorkerMessageHandler:i.Prism&&i.Prism.disableWorkerMessageHandler,util:{encode:function a(n){return n instanceof b?new b(n.type,a(n.content),n.alias):Array.isArray(n)?n.map(a):n.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/\u00a0/g," ")},type:function(a){return Object.prototype.toString.call(a).slice(8,-1)},objId:function(a){return a.__id||Object.defineProperty(a,"__id",{value:++p}),a.__id},clone:function a(n,r){var s,o;switch(r=r||{},l.util.type(n)){case"Object":if(o=l.util.objId(n),r[o])return r[o];for(var d in s={},r[o]=s,n)n.hasOwnProperty(d)&&(s[d]=a(n[d],r));return s;case"Array":return o=l.util.objId(n),r[o]?r[o]:(s=[],r[o]=s,n.forEach(function(u,g){s[g]=a(u,r)}),s);default:return n}},getLanguage:function(a){for(;a;){var n=c.exec(a.className);if(n)return n[1].toLowerCase();a=a.parentElement}return"none"},setLanguage:function(a,n){a.className=a.className.replace(RegExp(c,"gi"),""),a.classList.add("language-"+n)},currentScript:function(){if(typeof document>"u")return null;if(document.currentScript&&document.currentScript.tagName==="SCRIPT")return document.currentScript;try{throw new Error}catch(s){var a=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(s.stack)||[])[1];if(a){var n=document.getElementsByTagName("script");for(var r in n)if(n[r].src==a)return n[r]}return null}},isActive:function(a,n,r){for(var s="no-"+n;a;){var o=a.classList;if(o.contains(n))return!0;if(o.contains(s))return!1;a=a.parentElement}return!!r}},languages:{plain:f,plaintext:f,text:f,txt:f,extend:function(a,n){var r=l.util.clone(l.languages[a]);for(var s in n)r[s]=n[s];return r},insertBefore:function(a,n,r,s){var o=(s=s||l.languages)[a],d={};for(var u in o)if(o.hasOwnProperty(u)){if(u==n)for(var g in r)r.hasOwnProperty(g)&&(d[g]=r[g]);r.hasOwnProperty(u)||(d[u]=o[u])}var E=s[a];return s[a]=d,l.languages.DFS(l.languages,function(y,O){O===E&&y!=a&&(this[y]=d)}),d},DFS:function a(n,r,s,o){o=o||{};var d=l.util.objId;for(var u in n)if(n.hasOwnProperty(u)){r.call(n,u,n[u],s||u);var g=n[u],E=l.util.type(g);E!=="Object"||o[d(g)]?E!=="Array"||o[d(g)]||(o[d(g)]=!0,a(g,r,u,o)):(o[d(g)]=!0,a(g,r,null,o))}}},plugins:{},highlightAll:function(a,n){l.highlightAllUnder(document,a,n)},highlightAllUnder:function(a,n,r){var s={callback:r,container:a,selector:'code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'};l.hooks.run("before-highlightall",s),s.elements=Array.prototype.slice.apply(s.container.querySelectorAll(s.selector)),l.hooks.run("before-all-elements-highlight",s);for(var o,d=0;o=s.elements[d++];)l.highlightElement(o,n===!0,s.callback)},highlightElement:function(a,n,r){var s=l.util.getLanguage(a),o=l.languages[s];l.util.setLanguage(a,s);var d=a.parentElement;d&&d.nodeName.toLowerCase()==="pre"&&l.util.setLanguage(d,s);var u={element:a,language:s,grammar:o,code:a.textContent};function g(y){u.highlightedCode=y,l.hooks.run("before-insert",u),u.element.innerHTML=u.highlightedCode,l.hooks.run("after-highlight",u),l.hooks.run("complete",u),r&&r.call(u.element)}if(l.hooks.run("before-sanity-check",u),(d=u.element.parentElement)&&d.nodeName.toLowerCase()==="pre"&&!d.hasAttribute("tabindex")&&d.setAttribute("tabindex","0"),!u.code)return l.hooks.run("complete",u),void(r&&r.call(u.element));if(l.hooks.run("before-highlight",u),u.grammar)if(n&&i.Worker){var E=new Worker(l.filename);E.onmessage=function(y){g(y.data)},E.postMessage(JSON.stringify({language:u.language,code:u.code,immediateClose:!0}))}else g(l.highlight(u.code,u.grammar,u.language));else g(l.util.encode(u.code))},highlight:function(a,n,r){var s={code:a,grammar:n,language:r};if(l.hooks.run("before-tokenize",s),!s.grammar)throw new Error('The language "'+s.language+'" has no grammar.');return s.tokens=l.tokenize(s.code,s.grammar),l.hooks.run("after-tokenize",s),b.stringify(l.util.encode(s.tokens),s.language)},tokenize:function(a,n){var r=n.rest;if(r){for(var s in r)n[s]=r[s];delete n.rest}var o=new k;return S(o,o.head,a),m(a,o,n,o.head,0),function(d){for(var u=[],g=d.head.next;g!==d.tail;)u.push(g.value),g=g.next;return u}(o)},hooks:{all:{},add:function(a,n){var r=l.hooks.all;r[a]=r[a]||[],r[a].push(n)},run:function(a,n){var r=l.hooks.all[a];if(r&&r.length)for(var s,o=0;s=r[o++];)s(n)}},Token:b};function b(a,n,r,s){this.type=a,this.content=n,this.alias=r,this.length=0|(s||"").length}function h(a,n,r,s){a.lastIndex=n;var o=a.exec(r);if(o&&s&&o[1]){var d=o[1].length;o.index+=d,o[0]=o[0].slice(d)}return o}function m(a,n,r,s,o,d){for(var u in r)if(r.hasOwnProperty(u)&&r[u]){var g=r[u];g=Array.isArray(g)?g:[g];for(var E=0;E<g.length;++E){if(d&&d.cause==u+","+E)return;var y=g[E],O=y.inside,z=!!y.lookbehind,W=!!y.greedy,q=y.alias;if(W&&!y.pattern.global){var J=y.pattern.toString().match(/[imsuy]*$/)[0];y.pattern=RegExp(y.pattern.source,J+"g")}for(var Y=y.pattern||y,v=s.next,w=o;v!==n.tail&&!(d&&w>=d.reach);w+=v.value.length,v=v.next){var R=v.value;if(n.length>a.length)return;if(!(R instanceof b)){var x,N=1;if(W){if(!(x=h(Y,w,a,z))||x.index>=a.length)break;var P=x.index,Q=x.index+x[0].length,C=w;for(C+=v.value.length;P>=C;)C+=(v=v.next).value.length;if(w=C-=v.value.length,v.value instanceof b)continue;for(var F=v;F!==n.tail&&(C<Q||typeof F.value=="string");F=F.next)N++,C+=F.value.length;N--,R=a.slice(w,C),x.index-=w}else if(!(x=h(Y,0,R,z)))continue;P=x.index;var D=x[0],M=R.slice(0,P),X=R.slice(P+D.length),U=w+R.length;d&&U>d.reach&&(d.reach=U);var $=v.prev;if(M&&($=S(n,$,M),w+=M.length),T(n,$,N),v=S(n,$,new b(u,O?l.tokenize(D,O):D,q,D)),X&&S(n,v,X),N>1){var B={cause:u+","+E,reach:U};m(a,n,r,v.prev,w,B),d&&B.reach>d.reach&&(d.reach=B.reach)}}}}}}function k(){var a={value:null,prev:null,next:null},n={value:null,prev:a,next:null};a.next=n,this.head=a,this.tail=n,this.length=0}function S(a,n,r){var s=n.next,o={value:r,prev:n,next:s};return n.next=o,s.prev=o,a.length++,o}function T(a,n,r){for(var s=n.next,o=0;o<r&&s!==a.tail;o++)s=s.next;n.next=s,s.prev=n,a.length-=o}if(i.Prism=l,b.stringify=function a(n,r){if(typeof n=="string")return n;if(Array.isArray(n)){var s="";return n.forEach(function(E){s+=a(E,r)}),s}var o={type:n.type,content:a(n.content,r),tag:"span",classes:["token",n.type],attributes:{},language:r},d=n.alias;d&&(Array.isArray(d)?Array.prototype.push.apply(o.classes,d):o.classes.push(d)),l.hooks.run("wrap",o);var u="";for(var g in o.attributes)u+=" "+g+'="'+(o.attributes[g]||"").replace(/"/g,"&quot;")+'"';return"<"+o.tag+' class="'+o.classes.join(" ")+'"'+u+">"+o.content+"</"+o.tag+">"},!i.document)return i.addEventListener&&(l.disableWorkerMessageHandler||i.addEventListener("message",function(a){var n=JSON.parse(a.data),r=n.language,s=n.code,o=n.immediateClose;i.postMessage(l.highlight(s,l.languages[r],r)),o&&i.close()},!1)),l;var _=l.util.currentScript();function I(){l.manual||l.highlightAll()}if(_&&(l.filename=_.src,_.hasAttribute("data-manual")&&(l.manual=!0)),!l.manual){var A=document.readyState;A==="loading"||A==="interactive"&&_&&_.defer?document.addEventListener("DOMContentLoaded",I):window.requestAnimationFrame?window.requestAnimationFrame(I):window.setTimeout(I,16)}return l}(typeof window<"u"?window:typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope?self:{});e.exports&&(e.exports=t),K!==void 0&&(K.Prism=t),t.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},t.languages.markup.tag.inside["attr-value"].inside.entity=t.languages.markup.entity,t.languages.markup.doctype.inside["internal-subset"].inside=t.languages.markup,t.hooks.add("wrap",function(i){i.type==="entity"&&(i.attributes.title=i.content.replace(/&amp;/,"&"))}),Object.defineProperty(t.languages.markup.tag,"addInlined",{value:function(i,c){var p={};p["language-"+c]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:t.languages[c]},p.cdata=/^<!\[CDATA\[|\]\]>$/i;var f={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:p}};f["language-"+c]={pattern:/[\s\S]+/,inside:t.languages[c]};var l={};l[i]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return i}),"i"),lookbehind:!0,greedy:!0,inside:f},t.languages.insertBefore("markup","cdata",l)}}),Object.defineProperty(t.languages.markup.tag,"addAttribute",{value:function(i,c){t.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+i+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[c,"language-"+c],inside:t.languages[c]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),t.languages.html=t.languages.markup,t.languages.mathml=t.languages.markup,t.languages.svg=t.languages.markup,t.languages.xml=t.languages.extend("markup",{}),t.languages.ssml=t.languages.xml,t.languages.atom=t.languages.xml,t.languages.rss=t.languages.xml,function(i){var c=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;i.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+c.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+c.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+c.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+c.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:c,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},i.languages.css.atrule.inside.rest=i.languages.css;var p=i.languages.markup;p&&(p.tag.addInlined("style","css"),p.tag.addAttribute("style","css"))}(t),t.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},t.languages.javascript=t.languages.extend("clike",{"class-name":[t.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),t.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,t.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:t.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:t.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:t.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:t.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:t.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),t.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:t.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),t.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),t.languages.markup&&(t.languages.markup.tag.addInlined("script","javascript"),t.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),t.languages.js=t.languages.javascript,function(){if(t!==void 0&&typeof document<"u"){Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var i={js:"javascript",py:"python",rb:"ruby",ps1:"powershell",psm1:"powershell",sh:"bash",bat:"batch",h:"c",tex:"latex"},c="data-src-status",p="loading",f="loaded",l="pre[data-src]:not(["+c+'="'+f+'"]):not(['+c+'="'+p+'"])';t.hooks.add("before-highlightall",function(h){h.selector+=", "+l}),t.hooks.add("before-sanity-check",function(h){var m=h.element;if(m.matches(l)){h.code="",m.setAttribute(c,p);var k=m.appendChild(document.createElement("CODE"));k.textContent="Loading…";var S=m.getAttribute("data-src"),T=h.language;if(T==="none"){var _=(/\.(\w+)$/.exec(S)||[,"none"])[1];T=i[_]||_}t.util.setLanguage(k,T),t.util.setLanguage(m,T);var I=t.plugins.autoloader;I&&I.loadLanguages(T),function(A,a,n){var r=new XMLHttpRequest;r.open("GET",A,!0),r.onreadystatechange=function(){r.readyState==4&&(r.status<400&&r.responseText?a(r.responseText):r.status>=400?n("✖ Error "+r.status+" while fetching file: "+r.statusText):n("✖ Error: File does not exist or is empty"))},r.send(null)}(S,function(A){m.setAttribute(c,f);var a=function(o){var d=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(o||"");if(d){var u=Number(d[1]),g=d[2],E=d[3];return g?E?[u,Number(E)]:[u,void 0]:[u,u]}}(m.getAttribute("data-range"));if(a){var n=A.split(/\r\n?|\n/g),r=a[0],s=a[1]==null?n.length:a[1];r<0&&(r+=n.length),r=Math.max(0,Math.min(r-1,n.length)),s<0&&(s+=n.length),s=Math.max(0,Math.min(s,n.length)),A=n.slice(r,s).join(`
67
- `),m.hasAttribute("data-start")||m.setAttribute("data-start",String(r+1))}k.textContent=A,t.highlightElement(k)},function(A){m.setAttribute(c,"failed"),k.textContent=A})}}),t.plugins.fileHighlight={highlight:function(h){for(var m,k=(h||document).querySelectorAll(l),S=0;m=k[S++];)t.highlightElement(m)}};var b=!1;t.fileHighlight=function(){b||(b=!0),t.plugins.fileHighlight.highlight.apply(this,arguments)}}}()})(V);const j=ae(V.exports);Prism.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},Prism.languages.javascript=Prism.languages.extend("clike",{"class-name":[Prism.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),Prism.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,Prism.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:Prism.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:Prism.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),Prism.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:Prism.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),Prism.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),Prism.languages.markup&&(Prism.languages.markup.tag.addInlined("script","javascript"),Prism.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),Prism.languages.js=Prism.languages.javascript,Prism.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},Prism.languages.python["string-interpolation"].inside.interpolation.inside.rest=Prism.languages.python,Prism.languages.py=Prism.languages.python,Prism.languages.go=Prism.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),Prism.languages.insertBefore("go","string",{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete Prism.languages.go["class-name"],function(e){var t=/\b(?:abstract|assert|boolean|break|byte|case|catch|char|class|const|continue|default|do|double|else|enum|exports|extends|final|finally|float|for|goto|if|implements|import|instanceof|int|interface|long|module|native|new|non-sealed|null|open|opens|package|permits|private|protected|provides|public|record(?!\s*[(){}[\]<>=%~.:,;?+\-*/&|^])|requires|return|sealed|short|static|strictfp|super|switch|synchronized|this|throw|throws|to|transient|transitive|try|uses|var|void|volatile|while|with|yield)\b/,i=/(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source,c={pattern:RegExp(/(^|[^\w.])/.source+i+/[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),lookbehind:!0,inside:{namespace:{pattern:/^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,inside:{punctuation:/\./}},punctuation:/\./}};e.languages.java=e.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"/,lookbehind:!0,greedy:!0},"class-name":[c,{pattern:RegExp(/(^|[^\w.])/.source+i+/[A-Z]\w*(?=\s+\w+\s*[;,=()]|\s*(?:\[[\s,]*\]\s*)?::\s*new\b)/.source),lookbehind:!0,inside:c.inside},{pattern:RegExp(/(\b(?:class|enum|extends|implements|instanceof|interface|new|record|throws)\s+)/.source+i+/[A-Z]\w*\b/.source),lookbehind:!0,inside:c.inside}],keyword:t,function:[e.languages.clike.function,{pattern:/(::\s*)[a-z_]\w*/,lookbehind:!0}],number:/\b0b[01][01_]*L?\b|\b0x(?:\.[\da-f_p+-]+|[\da-f_]+(?:\.[\da-f_p+-]+)?)\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfl]?/i,operator:{pattern:/(^|[^.])(?:<<=?|>>>?=?|->|--|\+\+|&&|\|\||::|[?:~]|[-+*/%&|^!=<>]=?)/m,lookbehind:!0},constant:/\b[A-Z][A-Z_\d]+\b/}),e.languages.insertBefore("java","string",{"triple-quoted-string":{pattern:/"""[ \t]*[\r\n](?:(?:"|"")?(?:\\.|[^"\\]))*"""/,greedy:!0,alias:"string"},char:{pattern:/'(?:\\.|[^'\\\r\n]){1,6}'/,greedy:!0}}),e.languages.insertBefore("java","class-name",{annotation:{pattern:/(^|[^.])@\w+(?:\s*\.\s*\w+)*/,lookbehind:!0,alias:"punctuation"},generics:{pattern:/<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&))*>)*>)*>)*>/,inside:{"class-name":c,keyword:t,punctuation:/[<>(),.:]/,operator:/[?&|]/}},import:[{pattern:RegExp(/(\bimport\s+)/.source+i+/(?:[A-Z]\w*|\*)(?=\s*;)/.source),lookbehind:!0,inside:{namespace:c.inside.namespace,punctuation:/\./,operator:/\*/,"class-name":/\w+/}},{pattern:RegExp(/(\bimport\s+static\s+)/.source+i+/(?:\w+|\*)(?=\s*;)/.source),lookbehind:!0,alias:"static",inside:{namespace:c.inside.namespace,static:/\b\w+$/,punctuation:/\./,operator:/\*/,"class-name":/\w+/}}],namespace:{pattern:RegExp(/(\b(?:exports|import(?:\s+static)?|module|open|opens|package|provides|requires|to|transitive|uses|with)\s+)(?!<keyword>)[a-z]\w*(?:\.[a-z]\w*)*\.?/.source.replace(/<keyword>/g,function(){return t.source})),lookbehind:!0,inside:{punctuation:/\./}}})}(Prism),Prism.languages.c=Prism.languages.extend("clike",{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),Prism.languages.insertBefore("c","string",{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),Prism.languages.insertBefore("c","string",{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},Prism.languages.c.string],char:Prism.languages.c.char,comment:Prism.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:"function"}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:"keyword"},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:Prism.languages.c}}}}),Prism.languages.insertBefore("c","function",{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete Prism.languages.c.boolean,function(e){for(var t=/\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|<self>)*\*\//.source,i=0;i<2;i++)t=t.replace(/<self>/g,function(){return t});t=t.replace(/<self>/g,function(){return/[^\s\S]/.source}),e.languages.rust={comment:[{pattern:RegExp(/(^|[^\\])/.source+t),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:"attr-name",inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:"punctuation"},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:"symbol"},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:"punctuation"},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:"function"},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:"class-name"},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:"namespace"},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:"namespace",inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:"property"},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?=?|[@?]/},e.languages.rust["closure-params"].inside.rest=e.languages.rust,e.languages.rust.attribute.inside.string=e.languages.rust.string}(Prism),Prism.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/},function(e){var t="\\b(?:BASH|BASHOPTS|BASH_ALIASES|BASH_ARGC|BASH_ARGV|BASH_CMDS|BASH_COMPLETION_COMPAT_DIR|BASH_LINENO|BASH_REMATCH|BASH_SOURCE|BASH_VERSINFO|BASH_VERSION|COLORTERM|COLUMNS|COMP_WORDBREAKS|DBUS_SESSION_BUS_ADDRESS|DEFAULTS_PATH|DESKTOP_SESSION|DIRSTACK|DISPLAY|EUID|GDMSESSION|GDM_LANG|GNOME_KEYRING_CONTROL|GNOME_KEYRING_PID|GPG_AGENT_INFO|GROUPS|HISTCONTROL|HISTFILE|HISTFILESIZE|HISTSIZE|HOME|HOSTNAME|HOSTTYPE|IFS|INSTANCE|JOB|LANG|LANGUAGE|LC_ADDRESS|LC_ALL|LC_IDENTIFICATION|LC_MEASUREMENT|LC_MONETARY|LC_NAME|LC_NUMERIC|LC_PAPER|LC_TELEPHONE|LC_TIME|LESSCLOSE|LESSOPEN|LINES|LOGNAME|LS_COLORS|MACHTYPE|MAILCHECK|MANDATORY_PATH|NO_AT_BRIDGE|OLDPWD|OPTERR|OPTIND|ORBIT_SOCKETDIR|OSTYPE|PAPERSIZE|PATH|PIPESTATUS|PPID|PS1|PS2|PS3|PS4|PWD|RANDOM|REPLY|SECONDS|SELINUX_INIT|SESSION|SESSIONTYPE|SESSION_MANAGER|SHELL|SHELLOPTS|SHLVL|SSH_AUTH_SOCK|TERM|UID|UPSTART_EVENTS|UPSTART_INSTANCE|UPSTART_JOB|UPSTART_SESSION|USER|WINDOWID|XAUTHORITY|XDG_CONFIG_DIRS|XDG_CURRENT_DESKTOP|XDG_DATA_DIRS|XDG_GREETER_DATA_DIR|XDG_MENU_PREFIX|XDG_RUNTIME_DIR|XDG_SEAT|XDG_SEAT_PATH|XDG_SESSION_DESKTOP|XDG_SESSION_ID|XDG_SESSION_PATH|XDG_SESSION_TYPE|XDG_VTNR|XMODIFIERS)\\b",i={pattern:/(^(["']?)\w+\2)[ \t]+\S.*/,lookbehind:!0,alias:"punctuation",inside:null},c={bash:i,environment:{pattern:RegExp("\\$"+t),alias:"constant"},variable:[{pattern:/\$?\(\([\s\S]+?\)\)/,greedy:!0,inside:{variable:[{pattern:/(^\$\(\([\s\S]+)\)\)/,lookbehind:!0},/^\$\(\(/],number:/\b0x[\dA-Fa-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee]-?\d+)?/,operator:/--|\+\+|\*\*=?|<<=?|>>=?|&&|\|\||[=!+\-*/%<>^&|]=?|[?~:]/,punctuation:/\(\(?|\)\)?|,|;/}},{pattern:/\$\((?:\([^)]+\)|[^()])+\)|`[^`]+`/,greedy:!0,inside:{variable:/^\$\(|^`|\)$|`$/}},{pattern:/\$\{[^}]+\}/,greedy:!0,inside:{operator:/:[-=?+]?|[!\/]|##?|%%?|\^\^?|,,?/,punctuation:/[\[\]]/,environment:{pattern:RegExp("(\\{)"+t),lookbehind:!0,alias:"constant"}}},/\$(?:\w+|[#?*!@$])/],entity:/\\(?:[abceEfnrtv\\"]|O?[0-7]{1,3}|U[0-9a-fA-F]{8}|u[0-9a-fA-F]{4}|x[0-9a-fA-F]{1,2})/};e.languages.bash={shebang:{pattern:/^#!\s*\/.*/,alias:"important"},comment:{pattern:/(^|[^"{\\$])#.*/,lookbehind:!0},"function-name":[{pattern:/(\bfunction\s+)[\w-]+(?=(?:\s*\(?:\s*\))?\s*\{)/,lookbehind:!0,alias:"function"},{pattern:/\b[\w-]+(?=\s*\(\s*\)\s*\{)/,alias:"function"}],"for-or-select":{pattern:/(\b(?:for|select)\s+)\w+(?=\s+in\s)/,alias:"variable",lookbehind:!0},"assign-left":{pattern:/(^|[\s;|&]|[<>]\()\w+(?:\.\w+)*(?=\+?=)/,inside:{environment:{pattern:RegExp("(^|[\\s;|&]|[<>]\\()"+t),lookbehind:!0,alias:"constant"}},alias:"variable",lookbehind:!0},parameter:{pattern:/(^|\s)-{1,2}(?:\w+:[+-]?)?\w+(?:\.\w+)*(?=[=\s]|$)/,alias:"variable",lookbehind:!0},string:[{pattern:/((?:^|[^<])<<-?\s*)(\w+)\s[\s\S]*?(?:\r?\n|\r)\2/,lookbehind:!0,greedy:!0,inside:c},{pattern:/((?:^|[^<])<<-?\s*)(["'])(\w+)\2\s[\s\S]*?(?:\r?\n|\r)\3/,lookbehind:!0,greedy:!0,inside:{bash:i}},{pattern:/(^|[^\\](?:\\\\)*)"(?:\\[\s\S]|\$\([^)]+\)|\$(?!\()|`[^`]+`|[^"\\`$])*"/,lookbehind:!0,greedy:!0,inside:c},{pattern:/(^|[^$\\])'[^']*'/,lookbehind:!0,greedy:!0},{pattern:/\$'(?:[^'\\]|\\[\s\S])*'/,greedy:!0,inside:{entity:c.entity}}],environment:{pattern:RegExp("\\$?"+t),alias:"constant"},variable:c.variable,function:{pattern:/(^|[\s;|&]|[<>]\()(?:add|apropos|apt|apt-cache|apt-get|aptitude|aspell|automysqlbackup|awk|basename|bash|bc|bconsole|bg|bzip2|cal|cargo|cat|cfdisk|chgrp|chkconfig|chmod|chown|chroot|cksum|clear|cmp|column|comm|composer|cp|cron|crontab|csplit|curl|cut|date|dc|dd|ddrescue|debootstrap|df|diff|diff3|dig|dir|dircolors|dirname|dirs|dmesg|docker|docker-compose|du|egrep|eject|env|ethtool|expand|expect|expr|fdformat|fdisk|fg|fgrep|file|find|fmt|fold|format|free|fsck|ftp|fuser|gawk|git|gparted|grep|groupadd|groupdel|groupmod|groups|grub-mkconfig|gzip|halt|head|hg|history|host|hostname|htop|iconv|id|ifconfig|ifdown|ifup|import|install|ip|java|jobs|join|kill|killall|less|link|ln|locate|logname|logrotate|look|lpc|lpr|lprint|lprintd|lprintq|lprm|ls|lsof|lynx|make|man|mc|mdadm|mkconfig|mkdir|mke2fs|mkfifo|mkfs|mkisofs|mknod|mkswap|mmv|more|most|mount|mtools|mtr|mutt|mv|nano|nc|netstat|nice|nl|node|nohup|notify-send|npm|nslookup|op|open|parted|passwd|paste|pathchk|ping|pkill|pnpm|podman|podman-compose|popd|pr|printcap|printenv|ps|pushd|pv|quota|quotacheck|quotactl|ram|rar|rcp|reboot|remsync|rename|renice|rev|rm|rmdir|rpm|rsync|scp|screen|sdiff|sed|sendmail|seq|service|sftp|sh|shellcheck|shuf|shutdown|sleep|slocate|sort|split|ssh|stat|strace|su|sudo|sum|suspend|swapon|sync|sysctl|tac|tail|tar|tee|time|timeout|top|touch|tr|traceroute|tsort|tty|umount|uname|unexpand|uniq|units|unrar|unshar|unzip|update-grub|uptime|useradd|userdel|usermod|users|uudecode|uuencode|v|vcpkg|vdir|vi|vim|virsh|vmstat|wait|watch|wc|wget|whereis|which|who|whoami|write|xargs|xdg-open|yarn|yes|zenity|zip|zsh|zypper)(?=$|[)\s;|&])/,lookbehind:!0},keyword:{pattern:/(^|[\s;|&]|[<>]\()(?:case|do|done|elif|else|esac|fi|for|function|if|in|select|then|until|while)(?=$|[)\s;|&])/,lookbehind:!0},builtin:{pattern:/(^|[\s;|&]|[<>]\()(?:\.|:|alias|bind|break|builtin|caller|cd|command|continue|declare|echo|enable|eval|exec|exit|export|getopts|hash|help|let|local|logout|mapfile|printf|pwd|read|readarray|readonly|return|set|shift|shopt|source|test|times|trap|type|typeset|ulimit|umask|unalias|unset)(?=$|[)\s;|&])/,lookbehind:!0,alias:"class-name"},boolean:{pattern:/(^|[\s;|&]|[<>]\()(?:false|true)(?=$|[)\s;|&])/,lookbehind:!0},"file-descriptor":{pattern:/\B&\d\b/,alias:"important"},operator:{pattern:/\d?<>|>\||\+=|=[=~]?|!=?|<<[<-]?|[&\d]?>>|\d[<>]&?|[<>][&=]?|&[>&]?|\|[&|]?/,inside:{"file-descriptor":{pattern:/^\d/,alias:"important"}}},punctuation:/\$?\(\(?|\)\)?|\.\.|[{}[\];\\]/,number:{pattern:/(^|\s)(?:[1-9]\d*|0)(?:[.,]\d+)?\b/,lookbehind:!0}},i.inside=e.languages.bash;for(var p=["comment","function-name","for-or-select","assign-left","parameter","string","environment","function","keyword","builtin","boolean","file-descriptor","operator","punctuation","number"],f=c.variable[1].inside,l=0;l<p.length;l++)f[p[l]]=e.languages.bash[p[l]];e.languages.sh=e.languages.bash,e.languages.shell=e.languages.bash}(Prism),Prism.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"}},Prism.languages.webmanifest=Prism.languages.json;function G(e,t,i,c,p,f,l,b){var h=typeof e=="function"?e.options:e;return t&&(h.render=t,h.staticRenderFns=i,h._compiled=!0),f&&(h._scopeId="data-v-"+f),{exports:e,options:h}}typeof window<"u"&&(window.Prism=j);const L=G({name:"CodeRunner",components:{CodeEditor:G({name:"CodeEditor",props:{value:{type:String,default:""},language:{type:String,default:"javascript"},theme:{type:String,default:"dark"},disabled:{type:Boolean,default:!1}},data:function(){return{highlightRef:null,changeTimer:null}},mounted(){this.loadPrismTheme(this.theme)},watch:{theme(e){this.loadPrismTheme(e)}},computed:{languageMap:function(){return{javascript:"javascript",js:"javascript",typescript:"typescript",ts:"typescript",python:"python",py:"python",java:"java",c:"c",cpp:"cpp","c++":"cpp",csharp:"csharp","c#":"csharp",go:"go",golang:"go",rust:"rust",ruby:"ruby",rb:"ruby",php:"php",swift:"swift",kotlin:"kotlin",kt:"kotlin",sql:"sql",bash:"bash",sh:"bash",shell:"bash",json:"json",yaml:"yaml",yml:"yaml",markdown:"markdown",md:"markdown"}},prismLanguage:function(){return this.languageMap[this.language.toLowerCase()]||"javascript"},editorBackground:function(){return this.theme==="dark"?"#1e1e1e":"#fafafa"},highlightedCode:function(){try{var e=j.languages[this.prismLanguage];if(e)return j.highlight(this.value||"",e,this.prismLanguage)}catch{}return this.escapeHtml(this.value||"")}},methods:{loadPrismTheme(e){const t="hep-cr-prism-styles",i=document.getElementById(t),c=e==="dark"?`
66
+ This is a sample markdown document.`};var K=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ae(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var V={exports:{}};(function(e){var t=function(i){var c=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,p=0,f={},l={manual:i.Prism&&i.Prism.manual,disableWorkerMessageHandler:i.Prism&&i.Prism.disableWorkerMessageHandler,util:{encode:function a(n){return n instanceof b?new b(n.type,a(n.content),n.alias):Array.isArray(n)?n.map(a):n.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/\u00a0/g," ")},type:function(a){return Object.prototype.toString.call(a).slice(8,-1)},objId:function(a){return a.__id||Object.defineProperty(a,"__id",{value:++p}),a.__id},clone:function a(n,r){var s,o;switch(r=r||{},l.util.type(n)){case"Object":if(o=l.util.objId(n),r[o])return r[o];for(var d in s={},r[o]=s,n)n.hasOwnProperty(d)&&(s[d]=a(n[d],r));return s;case"Array":return o=l.util.objId(n),r[o]?r[o]:(s=[],r[o]=s,n.forEach(function(u,g){s[g]=a(u,r)}),s);default:return n}},getLanguage:function(a){for(;a;){var n=c.exec(a.className);if(n)return n[1].toLowerCase();a=a.parentElement}return"none"},setLanguage:function(a,n){a.className=a.className.replace(RegExp(c,"gi"),""),a.classList.add("language-"+n)},currentScript:function(){if(typeof document>"u")return null;if(document.currentScript&&document.currentScript.tagName==="SCRIPT")return document.currentScript;try{throw new Error}catch(s){var a=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(s.stack)||[])[1];if(a){var n=document.getElementsByTagName("script");for(var r in n)if(n[r].src==a)return n[r]}return null}},isActive:function(a,n,r){for(var s="no-"+n;a;){var o=a.classList;if(o.contains(n))return!0;if(o.contains(s))return!1;a=a.parentElement}return!!r}},languages:{plain:f,plaintext:f,text:f,txt:f,extend:function(a,n){var r=l.util.clone(l.languages[a]);for(var s in n)r[s]=n[s];return r},insertBefore:function(a,n,r,s){var o=(s=s||l.languages)[a],d={};for(var u in o)if(o.hasOwnProperty(u)){if(u==n)for(var g in r)r.hasOwnProperty(g)&&(d[g]=r[g]);r.hasOwnProperty(u)||(d[u]=o[u])}var E=s[a];return s[a]=d,l.languages.DFS(l.languages,function(y,O){O===E&&y!=a&&(this[y]=d)}),d},DFS:function a(n,r,s,o){o=o||{};var d=l.util.objId;for(var u in n)if(n.hasOwnProperty(u)){r.call(n,u,n[u],s||u);var g=n[u],E=l.util.type(g);E!=="Object"||o[d(g)]?E!=="Array"||o[d(g)]||(o[d(g)]=!0,a(g,r,u,o)):(o[d(g)]=!0,a(g,r,null,o))}}},plugins:{},highlightAll:function(a,n){l.highlightAllUnder(document,a,n)},highlightAllUnder:function(a,n,r){var s={callback:r,container:a,selector:'code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'};l.hooks.run("before-highlightall",s),s.elements=Array.prototype.slice.apply(s.container.querySelectorAll(s.selector)),l.hooks.run("before-all-elements-highlight",s);for(var o,d=0;o=s.elements[d++];)l.highlightElement(o,n===!0,s.callback)},highlightElement:function(a,n,r){var s=l.util.getLanguage(a),o=l.languages[s];l.util.setLanguage(a,s);var d=a.parentElement;d&&d.nodeName.toLowerCase()==="pre"&&l.util.setLanguage(d,s);var u={element:a,language:s,grammar:o,code:a.textContent};function g(y){u.highlightedCode=y,l.hooks.run("before-insert",u),u.element.innerHTML=u.highlightedCode,l.hooks.run("after-highlight",u),l.hooks.run("complete",u),r&&r.call(u.element)}if(l.hooks.run("before-sanity-check",u),(d=u.element.parentElement)&&d.nodeName.toLowerCase()==="pre"&&!d.hasAttribute("tabindex")&&d.setAttribute("tabindex","0"),!u.code)return l.hooks.run("complete",u),void(r&&r.call(u.element));if(l.hooks.run("before-highlight",u),u.grammar)if(n&&i.Worker){var E=new Worker(l.filename);E.onmessage=function(y){g(y.data)},E.postMessage(JSON.stringify({language:u.language,code:u.code,immediateClose:!0}))}else g(l.highlight(u.code,u.grammar,u.language));else g(l.util.encode(u.code))},highlight:function(a,n,r){var s={code:a,grammar:n,language:r};if(l.hooks.run("before-tokenize",s),!s.grammar)throw new Error('The language "'+s.language+'" has no grammar.');return s.tokens=l.tokenize(s.code,s.grammar),l.hooks.run("after-tokenize",s),b.stringify(l.util.encode(s.tokens),s.language)},tokenize:function(a,n){var r=n.rest;if(r){for(var s in r)n[s]=r[s];delete n.rest}var o=new k;return S(o,o.head,a),m(a,o,n,o.head,0),function(d){for(var u=[],g=d.head.next;g!==d.tail;)u.push(g.value),g=g.next;return u}(o)},hooks:{all:{},add:function(a,n){var r=l.hooks.all;r[a]=r[a]||[],r[a].push(n)},run:function(a,n){var r=l.hooks.all[a];if(r&&r.length)for(var s,o=0;s=r[o++];)s(n)}},Token:b};function b(a,n,r,s){this.type=a,this.content=n,this.alias=r,this.length=0|(s||"").length}function h(a,n,r,s){a.lastIndex=n;var o=a.exec(r);if(o&&s&&o[1]){var d=o[1].length;o.index+=d,o[0]=o[0].slice(d)}return o}function m(a,n,r,s,o,d){for(var u in r)if(r.hasOwnProperty(u)&&r[u]){var g=r[u];g=Array.isArray(g)?g:[g];for(var E=0;E<g.length;++E){if(d&&d.cause==u+","+E)return;var y=g[E],O=y.inside,W=!!y.lookbehind,Y=!!y.greedy,q=y.alias;if(Y&&!y.pattern.global){var J=y.pattern.toString().match(/[imsuy]*$/)[0];y.pattern=RegExp(y.pattern.source,J+"g")}for(var X=y.pattern||y,v=s.next,w=o;v!==n.tail&&!(d&&w>=d.reach);w+=v.value.length,v=v.next){var R=v.value;if(n.length>a.length)return;if(!(R instanceof b)){var x,N=1;if(Y){if(!(x=h(X,w,a,W))||x.index>=a.length)break;var P=x.index,Q=x.index+x[0].length,C=w;for(C+=v.value.length;P>=C;)C+=(v=v.next).value.length;if(w=C-=v.value.length,v.value instanceof b)continue;for(var F=v;F!==n.tail&&(C<Q||typeof F.value=="string");F=F.next)N++,C+=F.value.length;N--,R=a.slice(w,C),x.index-=w}else if(!(x=h(X,0,R,W)))continue;P=x.index;var D=x[0],M=R.slice(0,P),Z=R.slice(P+D.length),U=w+R.length;d&&U>d.reach&&(d.reach=U);var $=v.prev;if(M&&($=S(n,$,M),w+=M.length),T(n,$,N),v=S(n,$,new b(u,O?l.tokenize(D,O):D,q,D)),Z&&S(n,v,Z),N>1){var H={cause:u+","+E,reach:U};m(a,n,r,v.prev,w,H),d&&H.reach>d.reach&&(d.reach=H.reach)}}}}}}function k(){var a={value:null,prev:null,next:null},n={value:null,prev:a,next:null};a.next=n,this.head=a,this.tail=n,this.length=0}function S(a,n,r){var s=n.next,o={value:r,prev:n,next:s};return n.next=o,s.prev=o,a.length++,o}function T(a,n,r){for(var s=n.next,o=0;o<r&&s!==a.tail;o++)s=s.next;n.next=s,s.prev=n,a.length-=o}if(i.Prism=l,b.stringify=function a(n,r){if(typeof n=="string")return n;if(Array.isArray(n)){var s="";return n.forEach(function(E){s+=a(E,r)}),s}var o={type:n.type,content:a(n.content,r),tag:"span",classes:["token",n.type],attributes:{},language:r},d=n.alias;d&&(Array.isArray(d)?Array.prototype.push.apply(o.classes,d):o.classes.push(d)),l.hooks.run("wrap",o);var u="";for(var g in o.attributes)u+=" "+g+'="'+(o.attributes[g]||"").replace(/"/g,"&quot;")+'"';return"<"+o.tag+' class="'+o.classes.join(" ")+'"'+u+">"+o.content+"</"+o.tag+">"},!i.document)return i.addEventListener&&(l.disableWorkerMessageHandler||i.addEventListener("message",function(a){var n=JSON.parse(a.data),r=n.language,s=n.code,o=n.immediateClose;i.postMessage(l.highlight(s,l.languages[r],r)),o&&i.close()},!1)),l;var _=l.util.currentScript();function I(){l.manual||l.highlightAll()}if(_&&(l.filename=_.src,_.hasAttribute("data-manual")&&(l.manual=!0)),!l.manual){var A=document.readyState;A==="loading"||A==="interactive"&&_&&_.defer?document.addEventListener("DOMContentLoaded",I):window.requestAnimationFrame?window.requestAnimationFrame(I):window.setTimeout(I,16)}return l}(typeof window<"u"?window:typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope?self:{});e.exports&&(e.exports=t),K!==void 0&&(K.Prism=t),t.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},t.languages.markup.tag.inside["attr-value"].inside.entity=t.languages.markup.entity,t.languages.markup.doctype.inside["internal-subset"].inside=t.languages.markup,t.hooks.add("wrap",function(i){i.type==="entity"&&(i.attributes.title=i.content.replace(/&amp;/,"&"))}),Object.defineProperty(t.languages.markup.tag,"addInlined",{value:function(i,c){var p={};p["language-"+c]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:t.languages[c]},p.cdata=/^<!\[CDATA\[|\]\]>$/i;var f={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:p}};f["language-"+c]={pattern:/[\s\S]+/,inside:t.languages[c]};var l={};l[i]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return i}),"i"),lookbehind:!0,greedy:!0,inside:f},t.languages.insertBefore("markup","cdata",l)}}),Object.defineProperty(t.languages.markup.tag,"addAttribute",{value:function(i,c){t.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+i+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[c,"language-"+c],inside:t.languages[c]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),t.languages.html=t.languages.markup,t.languages.mathml=t.languages.markup,t.languages.svg=t.languages.markup,t.languages.xml=t.languages.extend("markup",{}),t.languages.ssml=t.languages.xml,t.languages.atom=t.languages.xml,t.languages.rss=t.languages.xml,function(i){var c=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;i.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+c.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+c.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+c.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+c.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:c,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},i.languages.css.atrule.inside.rest=i.languages.css;var p=i.languages.markup;p&&(p.tag.addInlined("style","css"),p.tag.addAttribute("style","css"))}(t),t.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},t.languages.javascript=t.languages.extend("clike",{"class-name":[t.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),t.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,t.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:t.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:t.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:t.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:t.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:t.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),t.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:t.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),t.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),t.languages.markup&&(t.languages.markup.tag.addInlined("script","javascript"),t.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),t.languages.js=t.languages.javascript,function(){if(t!==void 0&&typeof document<"u"){Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var i={js:"javascript",py:"python",rb:"ruby",ps1:"powershell",psm1:"powershell",sh:"bash",bat:"batch",h:"c",tex:"latex"},c="data-src-status",p="loading",f="loaded",l="pre[data-src]:not(["+c+'="'+f+'"]):not(['+c+'="'+p+'"])';t.hooks.add("before-highlightall",function(h){h.selector+=", "+l}),t.hooks.add("before-sanity-check",function(h){var m=h.element;if(m.matches(l)){h.code="",m.setAttribute(c,p);var k=m.appendChild(document.createElement("CODE"));k.textContent="Loading…";var S=m.getAttribute("data-src"),T=h.language;if(T==="none"){var _=(/\.(\w+)$/.exec(S)||[,"none"])[1];T=i[_]||_}t.util.setLanguage(k,T),t.util.setLanguage(m,T);var I=t.plugins.autoloader;I&&I.loadLanguages(T),function(A,a,n){var r=new XMLHttpRequest;r.open("GET",A,!0),r.onreadystatechange=function(){r.readyState==4&&(r.status<400&&r.responseText?a(r.responseText):r.status>=400?n("✖ Error "+r.status+" while fetching file: "+r.statusText):n("✖ Error: File does not exist or is empty"))},r.send(null)}(S,function(A){m.setAttribute(c,f);var a=function(o){var d=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(o||"");if(d){var u=Number(d[1]),g=d[2],E=d[3];return g?E?[u,Number(E)]:[u,void 0]:[u,u]}}(m.getAttribute("data-range"));if(a){var n=A.split(/\r\n?|\n/g),r=a[0],s=a[1]==null?n.length:a[1];r<0&&(r+=n.length),r=Math.max(0,Math.min(r-1,n.length)),s<0&&(s+=n.length),s=Math.max(0,Math.min(s,n.length)),A=n.slice(r,s).join(`
67
+ `),m.hasAttribute("data-start")||m.setAttribute("data-start",String(r+1))}k.textContent=A,t.highlightElement(k)},function(A){m.setAttribute(c,"failed"),k.textContent=A})}}),t.plugins.fileHighlight={highlight:function(h){for(var m,k=(h||document).querySelectorAll(l),S=0;m=k[S++];)t.highlightElement(m)}};var b=!1;t.fileHighlight=function(){b||(b=!0),t.plugins.fileHighlight.highlight.apply(this,arguments)}}}()})(V);const G=ae(V.exports);Prism.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},Prism.languages.javascript=Prism.languages.extend("clike",{"class-name":[Prism.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),Prism.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,Prism.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:Prism.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:Prism.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),Prism.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:Prism.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),Prism.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),Prism.languages.markup&&(Prism.languages.markup.tag.addInlined("script","javascript"),Prism.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),Prism.languages.js=Prism.languages.javascript,Prism.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},Prism.languages.python["string-interpolation"].inside.interpolation.inside.rest=Prism.languages.python,Prism.languages.py=Prism.languages.python,Prism.languages.go=Prism.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),Prism.languages.insertBefore("go","string",{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete Prism.languages.go["class-name"],function(e){var t=/\b(?:abstract|assert|boolean|break|byte|case|catch|char|class|const|continue|default|do|double|else|enum|exports|extends|final|finally|float|for|goto|if|implements|import|instanceof|int|interface|long|module|native|new|non-sealed|null|open|opens|package|permits|private|protected|provides|public|record(?!\s*[(){}[\]<>=%~.:,;?+\-*/&|^])|requires|return|sealed|short|static|strictfp|super|switch|synchronized|this|throw|throws|to|transient|transitive|try|uses|var|void|volatile|while|with|yield)\b/,i=/(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source,c={pattern:RegExp(/(^|[^\w.])/.source+i+/[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),lookbehind:!0,inside:{namespace:{pattern:/^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,inside:{punctuation:/\./}},punctuation:/\./}};e.languages.java=e.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"/,lookbehind:!0,greedy:!0},"class-name":[c,{pattern:RegExp(/(^|[^\w.])/.source+i+/[A-Z]\w*(?=\s+\w+\s*[;,=()]|\s*(?:\[[\s,]*\]\s*)?::\s*new\b)/.source),lookbehind:!0,inside:c.inside},{pattern:RegExp(/(\b(?:class|enum|extends|implements|instanceof|interface|new|record|throws)\s+)/.source+i+/[A-Z]\w*\b/.source),lookbehind:!0,inside:c.inside}],keyword:t,function:[e.languages.clike.function,{pattern:/(::\s*)[a-z_]\w*/,lookbehind:!0}],number:/\b0b[01][01_]*L?\b|\b0x(?:\.[\da-f_p+-]+|[\da-f_]+(?:\.[\da-f_p+-]+)?)\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfl]?/i,operator:{pattern:/(^|[^.])(?:<<=?|>>>?=?|->|--|\+\+|&&|\|\||::|[?:~]|[-+*/%&|^!=<>]=?)/m,lookbehind:!0},constant:/\b[A-Z][A-Z_\d]+\b/}),e.languages.insertBefore("java","string",{"triple-quoted-string":{pattern:/"""[ \t]*[\r\n](?:(?:"|"")?(?:\\.|[^"\\]))*"""/,greedy:!0,alias:"string"},char:{pattern:/'(?:\\.|[^'\\\r\n]){1,6}'/,greedy:!0}}),e.languages.insertBefore("java","class-name",{annotation:{pattern:/(^|[^.])@\w+(?:\s*\.\s*\w+)*/,lookbehind:!0,alias:"punctuation"},generics:{pattern:/<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&))*>)*>)*>)*>/,inside:{"class-name":c,keyword:t,punctuation:/[<>(),.:]/,operator:/[?&|]/}},import:[{pattern:RegExp(/(\bimport\s+)/.source+i+/(?:[A-Z]\w*|\*)(?=\s*;)/.source),lookbehind:!0,inside:{namespace:c.inside.namespace,punctuation:/\./,operator:/\*/,"class-name":/\w+/}},{pattern:RegExp(/(\bimport\s+static\s+)/.source+i+/(?:\w+|\*)(?=\s*;)/.source),lookbehind:!0,alias:"static",inside:{namespace:c.inside.namespace,static:/\b\w+$/,punctuation:/\./,operator:/\*/,"class-name":/\w+/}}],namespace:{pattern:RegExp(/(\b(?:exports|import(?:\s+static)?|module|open|opens|package|provides|requires|to|transitive|uses|with)\s+)(?!<keyword>)[a-z]\w*(?:\.[a-z]\w*)*\.?/.source.replace(/<keyword>/g,function(){return t.source})),lookbehind:!0,inside:{punctuation:/\./}}})}(Prism),Prism.languages.c=Prism.languages.extend("clike",{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),Prism.languages.insertBefore("c","string",{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),Prism.languages.insertBefore("c","string",{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},Prism.languages.c.string],char:Prism.languages.c.char,comment:Prism.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:"function"}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:"keyword"},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:Prism.languages.c}}}}),Prism.languages.insertBefore("c","function",{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete Prism.languages.c.boolean,function(e){for(var t=/\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|<self>)*\*\//.source,i=0;i<2;i++)t=t.replace(/<self>/g,function(){return t});t=t.replace(/<self>/g,function(){return/[^\s\S]/.source}),e.languages.rust={comment:[{pattern:RegExp(/(^|[^\\])/.source+t),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:"attr-name",inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:"punctuation"},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:"symbol"},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:"punctuation"},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:"function"},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:"class-name"},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:"namespace"},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:"namespace",inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:"property"},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?=?|[@?]/},e.languages.rust["closure-params"].inside.rest=e.languages.rust,e.languages.rust.attribute.inside.string=e.languages.rust.string}(Prism),Prism.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/},function(e){var t="\\b(?:BASH|BASHOPTS|BASH_ALIASES|BASH_ARGC|BASH_ARGV|BASH_CMDS|BASH_COMPLETION_COMPAT_DIR|BASH_LINENO|BASH_REMATCH|BASH_SOURCE|BASH_VERSINFO|BASH_VERSION|COLORTERM|COLUMNS|COMP_WORDBREAKS|DBUS_SESSION_BUS_ADDRESS|DEFAULTS_PATH|DESKTOP_SESSION|DIRSTACK|DISPLAY|EUID|GDMSESSION|GDM_LANG|GNOME_KEYRING_CONTROL|GNOME_KEYRING_PID|GPG_AGENT_INFO|GROUPS|HISTCONTROL|HISTFILE|HISTFILESIZE|HISTSIZE|HOME|HOSTNAME|HOSTTYPE|IFS|INSTANCE|JOB|LANG|LANGUAGE|LC_ADDRESS|LC_ALL|LC_IDENTIFICATION|LC_MEASUREMENT|LC_MONETARY|LC_NAME|LC_NUMERIC|LC_PAPER|LC_TELEPHONE|LC_TIME|LESSCLOSE|LESSOPEN|LINES|LOGNAME|LS_COLORS|MACHTYPE|MAILCHECK|MANDATORY_PATH|NO_AT_BRIDGE|OLDPWD|OPTERR|OPTIND|ORBIT_SOCKETDIR|OSTYPE|PAPERSIZE|PATH|PIPESTATUS|PPID|PS1|PS2|PS3|PS4|PWD|RANDOM|REPLY|SECONDS|SELINUX_INIT|SESSION|SESSIONTYPE|SESSION_MANAGER|SHELL|SHELLOPTS|SHLVL|SSH_AUTH_SOCK|TERM|UID|UPSTART_EVENTS|UPSTART_INSTANCE|UPSTART_JOB|UPSTART_SESSION|USER|WINDOWID|XAUTHORITY|XDG_CONFIG_DIRS|XDG_CURRENT_DESKTOP|XDG_DATA_DIRS|XDG_GREETER_DATA_DIR|XDG_MENU_PREFIX|XDG_RUNTIME_DIR|XDG_SEAT|XDG_SEAT_PATH|XDG_SESSION_DESKTOP|XDG_SESSION_ID|XDG_SESSION_PATH|XDG_SESSION_TYPE|XDG_VTNR|XMODIFIERS)\\b",i={pattern:/(^(["']?)\w+\2)[ \t]+\S.*/,lookbehind:!0,alias:"punctuation",inside:null},c={bash:i,environment:{pattern:RegExp("\\$"+t),alias:"constant"},variable:[{pattern:/\$?\(\([\s\S]+?\)\)/,greedy:!0,inside:{variable:[{pattern:/(^\$\(\([\s\S]+)\)\)/,lookbehind:!0},/^\$\(\(/],number:/\b0x[\dA-Fa-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee]-?\d+)?/,operator:/--|\+\+|\*\*=?|<<=?|>>=?|&&|\|\||[=!+\-*/%<>^&|]=?|[?~:]/,punctuation:/\(\(?|\)\)?|,|;/}},{pattern:/\$\((?:\([^)]+\)|[^()])+\)|`[^`]+`/,greedy:!0,inside:{variable:/^\$\(|^`|\)$|`$/}},{pattern:/\$\{[^}]+\}/,greedy:!0,inside:{operator:/:[-=?+]?|[!\/]|##?|%%?|\^\^?|,,?/,punctuation:/[\[\]]/,environment:{pattern:RegExp("(\\{)"+t),lookbehind:!0,alias:"constant"}}},/\$(?:\w+|[#?*!@$])/],entity:/\\(?:[abceEfnrtv\\"]|O?[0-7]{1,3}|U[0-9a-fA-F]{8}|u[0-9a-fA-F]{4}|x[0-9a-fA-F]{1,2})/};e.languages.bash={shebang:{pattern:/^#!\s*\/.*/,alias:"important"},comment:{pattern:/(^|[^"{\\$])#.*/,lookbehind:!0},"function-name":[{pattern:/(\bfunction\s+)[\w-]+(?=(?:\s*\(?:\s*\))?\s*\{)/,lookbehind:!0,alias:"function"},{pattern:/\b[\w-]+(?=\s*\(\s*\)\s*\{)/,alias:"function"}],"for-or-select":{pattern:/(\b(?:for|select)\s+)\w+(?=\s+in\s)/,alias:"variable",lookbehind:!0},"assign-left":{pattern:/(^|[\s;|&]|[<>]\()\w+(?:\.\w+)*(?=\+?=)/,inside:{environment:{pattern:RegExp("(^|[\\s;|&]|[<>]\\()"+t),lookbehind:!0,alias:"constant"}},alias:"variable",lookbehind:!0},parameter:{pattern:/(^|\s)-{1,2}(?:\w+:[+-]?)?\w+(?:\.\w+)*(?=[=\s]|$)/,alias:"variable",lookbehind:!0},string:[{pattern:/((?:^|[^<])<<-?\s*)(\w+)\s[\s\S]*?(?:\r?\n|\r)\2/,lookbehind:!0,greedy:!0,inside:c},{pattern:/((?:^|[^<])<<-?\s*)(["'])(\w+)\2\s[\s\S]*?(?:\r?\n|\r)\3/,lookbehind:!0,greedy:!0,inside:{bash:i}},{pattern:/(^|[^\\](?:\\\\)*)"(?:\\[\s\S]|\$\([^)]+\)|\$(?!\()|`[^`]+`|[^"\\`$])*"/,lookbehind:!0,greedy:!0,inside:c},{pattern:/(^|[^$\\])'[^']*'/,lookbehind:!0,greedy:!0},{pattern:/\$'(?:[^'\\]|\\[\s\S])*'/,greedy:!0,inside:{entity:c.entity}}],environment:{pattern:RegExp("\\$?"+t),alias:"constant"},variable:c.variable,function:{pattern:/(^|[\s;|&]|[<>]\()(?:add|apropos|apt|apt-cache|apt-get|aptitude|aspell|automysqlbackup|awk|basename|bash|bc|bconsole|bg|bzip2|cal|cargo|cat|cfdisk|chgrp|chkconfig|chmod|chown|chroot|cksum|clear|cmp|column|comm|composer|cp|cron|crontab|csplit|curl|cut|date|dc|dd|ddrescue|debootstrap|df|diff|diff3|dig|dir|dircolors|dirname|dirs|dmesg|docker|docker-compose|du|egrep|eject|env|ethtool|expand|expect|expr|fdformat|fdisk|fg|fgrep|file|find|fmt|fold|format|free|fsck|ftp|fuser|gawk|git|gparted|grep|groupadd|groupdel|groupmod|groups|grub-mkconfig|gzip|halt|head|hg|history|host|hostname|htop|iconv|id|ifconfig|ifdown|ifup|import|install|ip|java|jobs|join|kill|killall|less|link|ln|locate|logname|logrotate|look|lpc|lpr|lprint|lprintd|lprintq|lprm|ls|lsof|lynx|make|man|mc|mdadm|mkconfig|mkdir|mke2fs|mkfifo|mkfs|mkisofs|mknod|mkswap|mmv|more|most|mount|mtools|mtr|mutt|mv|nano|nc|netstat|nice|nl|node|nohup|notify-send|npm|nslookup|op|open|parted|passwd|paste|pathchk|ping|pkill|pnpm|podman|podman-compose|popd|pr|printcap|printenv|ps|pushd|pv|quota|quotacheck|quotactl|ram|rar|rcp|reboot|remsync|rename|renice|rev|rm|rmdir|rpm|rsync|scp|screen|sdiff|sed|sendmail|seq|service|sftp|sh|shellcheck|shuf|shutdown|sleep|slocate|sort|split|ssh|stat|strace|su|sudo|sum|suspend|swapon|sync|sysctl|tac|tail|tar|tee|time|timeout|top|touch|tr|traceroute|tsort|tty|umount|uname|unexpand|uniq|units|unrar|unshar|unzip|update-grub|uptime|useradd|userdel|usermod|users|uudecode|uuencode|v|vcpkg|vdir|vi|vim|virsh|vmstat|wait|watch|wc|wget|whereis|which|who|whoami|write|xargs|xdg-open|yarn|yes|zenity|zip|zsh|zypper)(?=$|[)\s;|&])/,lookbehind:!0},keyword:{pattern:/(^|[\s;|&]|[<>]\()(?:case|do|done|elif|else|esac|fi|for|function|if|in|select|then|until|while)(?=$|[)\s;|&])/,lookbehind:!0},builtin:{pattern:/(^|[\s;|&]|[<>]\()(?:\.|:|alias|bind|break|builtin|caller|cd|command|continue|declare|echo|enable|eval|exec|exit|export|getopts|hash|help|let|local|logout|mapfile|printf|pwd|read|readarray|readonly|return|set|shift|shopt|source|test|times|trap|type|typeset|ulimit|umask|unalias|unset)(?=$|[)\s;|&])/,lookbehind:!0,alias:"class-name"},boolean:{pattern:/(^|[\s;|&]|[<>]\()(?:false|true)(?=$|[)\s;|&])/,lookbehind:!0},"file-descriptor":{pattern:/\B&\d\b/,alias:"important"},operator:{pattern:/\d?<>|>\||\+=|=[=~]?|!=?|<<[<-]?|[&\d]?>>|\d[<>]&?|[<>][&=]?|&[>&]?|\|[&|]?/,inside:{"file-descriptor":{pattern:/^\d/,alias:"important"}}},punctuation:/\$?\(\(?|\)\)?|\.\.|[{}[\];\\]/,number:{pattern:/(^|\s)(?:[1-9]\d*|0)(?:[.,]\d+)?\b/,lookbehind:!0}},i.inside=e.languages.bash;for(var p=["comment","function-name","for-or-select","assign-left","parameter","string","environment","function","keyword","builtin","boolean","file-descriptor","operator","punctuation","number"],f=c.variable[1].inside,l=0;l<p.length;l++)f[p[l]]=e.languages.bash[p[l]];e.languages.sh=e.languages.bash,e.languages.shell=e.languages.bash}(Prism),Prism.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"}},Prism.languages.webmanifest=Prism.languages.json;function z(e,t,i,c,p,f,l,b){var h=typeof e=="function"?e.options:e;return t&&(h.render=t,h.staticRenderFns=i,h._compiled=!0),f&&(h._scopeId="data-v-"+f),{exports:e,options:h}}typeof window<"u"&&(window.Prism=G);const L=z({name:"CodeRunner",components:{CodeEditor:z({name:"CodeEditor",props:{value:{type:String,default:""},language:{type:String,default:"javascript"},theme:{type:String,default:"dark"},disabled:{type:Boolean,default:!1}},data:function(){return{highlightRef:null,changeTimer:null}},mounted(){this.loadPrismTheme(this.theme)},watch:{theme(e){this.loadPrismTheme(e)}},computed:{languageMap:function(){return{javascript:"javascript",js:"javascript",typescript:"typescript",ts:"typescript",python:"python",py:"python",java:"java",c:"c",cpp:"cpp","c++":"cpp",csharp:"csharp","c#":"csharp",go:"go",golang:"go",rust:"rust",ruby:"ruby",rb:"ruby",php:"php",swift:"swift",kotlin:"kotlin",kt:"kotlin",sql:"sql",bash:"bash",sh:"bash",shell:"bash",json:"json",yaml:"yaml",yml:"yaml",markdown:"markdown",md:"markdown"}},prismLanguage:function(){return this.languageMap[this.language.toLowerCase()]||"javascript"},editorBackground:function(){return this.theme==="dark"?"#1e1e1e":"#fafafa"},highlightedCode:function(){try{var e=G.languages[this.prismLanguage];if(e)return G.highlight(this.value||"",e,this.prismLanguage)}catch{}return this.escapeHtml(this.value||"")}},methods:{loadPrismTheme(e){const t="hep-cr-prism-styles",i=document.getElementById(t),c=e==="dark"?`
68
68
  /* 默认代码颜色 */
69
69
  .hep-cr-editor .hep-cr-highlight code,
70
70
  .hep-cr-editor .hep-cr-highlight pre {
@@ -225,5 +225,5 @@ This is a sample markdown document.`};var K=typeof globalThis<"u"?globalThis:typ
225
225
  .hep-cr-editor .token.console {
226
226
  color: #333 !important;
227
227
  }
228
- `;i&&i.remove();const p=document.createElement("style");p.id=t,p.textContent=c,document.head.appendChild(p)},escapeHtml:function(e){var t=document.createElement("div");return t.textContent=e,t.innerHTML},handleInput:function(e){this.$emit("input",e.target.value),this.$emit("update:value",e.target.value),this.emitChange(e.target.value)},handleScroll:function(e){var t=this.$refs.highlightRef;t&&(t.scrollTop=e.target.scrollTop,t.scrollLeft=e.target.scrollLeft)},handleKeydown:function(e){if(e.key==="Tab"){e.preventDefault();var t=e.target,i=t.selectionStart,c=t.selectionEnd,p=t.value;t.value=p.substring(0,i)+" "+p.substring(c),t.selectionStart=t.selectionEnd=i+2,this.$emit("input",t.value),this.$emit("update:value",t.value),this.emitChange(t.value)}},emitChange:function(e){var t=this;t.changeTimer&&clearTimeout(t.changeTimer),t.changeTimer=setTimeout(function(){t.$emit("change",e)},500)}},beforeDestroy:function(){this.changeTimer&&clearTimeout(this.changeTimer)}},function(){var e=this,t=e._self._c;return t("div",{staticClass:"hep-cr-editor",class:"hep-cr-theme-"+e.theme,style:{background:e.editorBackground}},[t("pre",{ref:"highlightRef",staticClass:"hep-cr-highlight",class:"language-"+e.prismLanguage,attrs:{"aria-hidden":"true"}},[t("code",{domProps:{innerHTML:e._s(e.highlightedCode)}})]),t("textarea",{staticClass:"hep-cr-input",attrs:{disabled:e.disabled,spellcheck:"false",placeholder:"请输入代码..."},domProps:{value:e.value},on:{input:e.handleInput,scroll:e.handleScroll,keydown:e.handleKeydown}})])},[],0,0,"c5a23c34").exports},props:{pistonUrl:{type:String,default:"/api/piston"},language:{type:String,default:"javascript"},code:{type:String,default:""},theme:{type:String,default:"light",validator:function(e){return["light","dark"].indexOf(e)!==-1}},themeColor:{type:String,default:""},showLanguageSelector:{type:Boolean,default:!0},showEditor:{type:Boolean,default:!0},editable:{type:Boolean,default:!0},executorLabel:{type:String,default:"运行"}},data:function(){return{runtimes:[],isCodeModified:!1,internalLanguage:this.language||"javascript",internalCode:this.code!==void 0?this.code:"",currentTheme:this.theme,output:"",stderr:"",isRunning:!1,executionTime:null,activeTab:"stdout",error:null,runtimesLoading:!1,client:null,editorWidth:60,copiedEditor:!1,copiedOutput:!1}},computed:{themeClass:function(){return"hep-cr-runner-"+this.currentTheme},themeStyle:function(){if(!this.themeColor)return{};var e,t=this.currentTheme==="dark",i=this.themeColor,c=function(f,l){var b=parseInt(f.replace("#",""),16),h=Math.round(2.55*l);return"#"+(16777216+65536*Math.min(255,Math.max(0,(b>>16)+h))+256*Math.min(255,Math.max(0,(b>>8&255)+h))+Math.min(255,Math.max(0,(255&b)+h))).toString(16).slice(1)},p=(.299*((e=parseInt(i.replace("#",""),16))>>16&255)+.587*(e>>8&255)+.114*(255&e))/255>.5?"#000":"#fff";return{"--hep-cr-theme-color":i,"--hep-cr-theme-color-hover":c(i,t?20:-20),"--hep-cr-tab-active-color":p}},languageOptions:function(){return this.runtimes.map(function(e){return{value:e.language+":"+e.version,label:e.language.charAt(0).toUpperCase()+e.language.slice(1)+" "+e.version}})},languageName:function(){var e=this.internalLanguage;return e.includes(":")?e.split(":")[0]:e}},watch:{language:function(e){e&&e!==this.internalLanguage&&(this.internalLanguage=e)},code:function(e){e!==void 0&&e!==this.internalCode&&(this.internalCode=e)},language:function(e){e&&e!==this.internalLanguage&&(this.internalLanguage=e)},internalLanguage:function(e){this.isCodeModified||(this.internalCode=function(t){const i=t.toLowerCase();return ne[i]||`// ${t}
229
- // Write your code here`}(e)),this.isCodeModified=!1,this.$emit("update:language",e),this.$emit("language-change",e.includes(":")?e.split(":")[0]:e,this.internalCode)},internalCode:function(e){this.$emit("update:code",e),this.$emit("change",e)}},mounted:function(){this.client=new te({pistonUrl:this.pistonUrl}),this.loadRuntimes()},methods:{loadRuntimes:function(){var e=this;this.runtimesLoading=!0,this.error=null,this.client.getRuntimes().then(function(t){e.runtimes=t;var i=e.languageName,c=t.find(function(p){return p.language===i});c&&!e.internalLanguage.includes(":")&&(e.internalLanguage=i+":"+c.version)}).catch(function(t){e.error=t.message||"Failed to load runtimes"}).finally(function(){e.runtimesLoading=!1})},handleCodeInput:function(e){this.isCodeModified=!0,this.internalCode=e},handleCodeChange:function(e){this.internalCode=e},execute:function(){var e=this;this.isRunning||(this.isRunning=!0,this.output="",this.stderr="",this.executionTime=null,this.error=null,this.activeTab="stdout",this.$emit("execute-start"),this.client.execute(this.languageName,this.internalCode).then(function(t){e.output=t.output,e.stderr=t.stderr,e.executionTime=t.executionTime||null,e.activeTab=t.stderr?"stderr":"stdout",e.$emit("execute-end",t)}).catch(function(t){e.error=t.message||"Execution failed",e.$emit("execute-end",{success:!1,output:"",stderr:e.error,code:-1})}).finally(function(){e.isRunning=!1}))},clearOutput:function(){this.output="",this.stderr="",this.executionTime=null,this.error=null},copyCode:function(){var e=this;navigator.clipboard.writeText(this.internalCode),this.copiedEditor=!0,setTimeout(function(){e.copiedEditor=!1},2e3)},copyOutput:function(){var e=this,t=this.activeTab==="stdout"?this.output:this.stderr;navigator.clipboard.writeText(t),this.copiedOutput=!0,setTimeout(function(){e.copiedOutput=!1},2e3)},toggleTheme:function(){this.currentTheme=this.currentTheme==="light"?"dark":"light"},startDrag:function(e){var t=this,i=document.querySelector(".hep-cr-runner-main");if(i){var c=function(f){var l=i.getBoundingClientRect(),b=(f.clientX-l.left)/l.width*100;t.editorWidth=Math.max(20,Math.min(80,b))},p=function(){document.removeEventListener("mousemove",c),document.removeEventListener("mouseup",p),document.body.style.cursor="",document.body.style.userSelect=""};document.addEventListener("mousemove",c),document.addEventListener("mouseup",p),document.body.style.cursor="col-resize",document.body.style.userSelect="none"}}}},function(){var e=this,t=e._self._c;return t("div",{class:["hep-cr-runner",e.themeClass],style:e.themeStyle},[t("div",{staticClass:"hep-cr-runner-header"},[t("div",{staticClass:"hep-cr-runner-controls"},[e.showLanguageSelector?t("select",{directives:[{name:"model",rawName:"v-model",value:e.internalLanguage,expression:"internalLanguage"}],staticClass:"hep-cr-language-select",attrs:{disabled:e.isRunning},on:{change:function(i){var c=Array.prototype.filter.call(i.target.options,function(p){return p.selected}).map(function(p){return"_value"in p?p._value:p.value});e.internalLanguage=i.target.multiple?c:c[0]}}},[e.runtimesLoading?t("option",{attrs:{value:""}},[e._v("加载中...")]):e._e(),e._l(e.languageOptions,function(i){return t("option",{key:i.value,domProps:{value:i.value}},[e._v(" "+e._s(i.label)+" ")])})],2):e._e()]),t("div",{staticClass:"hep-cr-runner-actions"},[t("button",{staticClass:"hep-cr-btn hep-cr-btn-run",attrs:{disabled:e.isRunning||e.runtimesLoading},on:{click:e.execute}},[e.isRunning?t("span",{staticClass:"hep-cr-spinner"}):t("span",{staticClass:"hep-cr-run-icon"},[e._v("▶")]),e._v(" "+e._s(e.isRunning?"运行中...":e.executorLabel)+" ")]),t("button",{staticClass:"hep-cr-btn hep-cr-btn-theme",attrs:{title:e.currentTheme==="light"?"Switch to dark mode":"Switch to light mode"},on:{click:e.toggleTheme}},[e.currentTheme==="light"?t("svg",{attrs:{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"}},[t("path",{attrs:{d:"M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z"}})]):t("svg",{attrs:{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"}},[t("circle",{attrs:{cx:"12",cy:"12",r:"5"}}),t("line",{attrs:{x1:"12",y1:"1",x2:"12",y2:"3"}}),t("line",{attrs:{x1:"12",y1:"21",x2:"12",y2:"23"}}),t("line",{attrs:{x1:"4.22",y1:"4.22",x2:"5.64",y2:"5.64"}}),t("line",{attrs:{x1:"18.36",y1:"18.36",x2:"19.78",y2:"19.78"}}),t("line",{attrs:{x1:"1",y1:"12",x2:"3",y2:"12"}}),t("line",{attrs:{x1:"21",y1:"12",x2:"23",y2:"12"}}),t("line",{attrs:{x1:"4.22",y1:"19.78",x2:"5.64",y2:"18.36"}}),t("line",{attrs:{x1:"18.36",y1:"5.64",x2:"19.78",y2:"4.22"}})])])])]),e.error?t("div",{staticClass:"hep-cr-error-message"},[e._v(" "+e._s(e.error)+" ")]):e._e(),t("div",{staticClass:"hep-cr-runner-main"},[e.showEditor?t("div",{staticClass:"hep-cr-editor-panel",style:{width:e.editorWidth+"%"}},[t("div",{staticClass:"hep-cr-panel-header"},[t("span",{staticClass:"hep-cr-panel-title"},[e._v("编辑器")]),t("div",{staticClass:"hep-cr-output-actions"},[t("span",{staticClass:"hep-cr-language-badge"},[e._v(e._s(e.languageName))]),t("button",{staticClass:"hep-cr-btn-icon",class:{"hep-cr-btn-copied":e.copiedEditor},attrs:{disabled:e.copiedEditor,title:e.copiedEditor?"已复制":"复制"},on:{click:e.copyCode}},[e.copiedEditor?t("span",{staticClass:"hep-cr-copied-text"},[e._v("已复制")]):t("svg",{attrs:{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"}},[t("rect",{attrs:{x:"9",y:"9",width:"13",height:"13",rx:"2",ry:"2"}}),t("path",{attrs:{d:"M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"}})])])])]),t("CodeEditor",{attrs:{value:e.internalCode,language:e.languageName,theme:e.currentTheme,disabled:!e.editable||e.isRunning},on:{input:e.handleCodeInput,change:e.handleCodeChange}})],1):e._e(),e.showEditor?t("div",{staticClass:"hep-cr-resize-handle",on:{mousedown:e.startDrag}},[t("div",{staticClass:"hep-cr-resize-line"})]):e._e(),t("div",{staticClass:"hep-cr-output-panel",style:{width:e.showEditor?100-e.editorWidth+"%":"100%"}},[t("div",{staticClass:"hep-cr-panel-header"},[t("div",{staticClass:"hep-cr-output-tabs"},[t("button",{class:["hep-cr-tab",{active:e.activeTab==="stdout"}],on:{click:function(i){e.activeTab="stdout"}}},[e._v(" 输出 ")]),e.stderr?t("button",{class:["hep-cr-tab","hep-cr-tab-error",{active:e.activeTab==="stderr"}],on:{click:function(i){e.activeTab="stderr"}}},[e._v(" 错误 ")]):e._e()]),t("div",{staticClass:"hep-cr-output-actions"},[e.executionTime!==null?t("span",{staticClass:"hep-cr-execution-time"},[e._v(" "+e._s(e.executionTime)+"ms ")]):e._e(),t("button",{staticClass:"hep-cr-btn-icon",class:{"hep-cr-btn-copied":e.copiedOutput},attrs:{disabled:e.copiedOutput,title:e.copiedOutput?"已复制":"复制"},on:{click:e.copyOutput}},[e.copiedOutput?t("span",{staticClass:"hep-cr-copied-text"},[e._v("已复制")]):t("svg",{attrs:{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"}},[t("rect",{attrs:{x:"9",y:"9",width:"13",height:"13",rx:"2",ry:"2"}}),t("path",{attrs:{d:"M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"}})])])])]),t("div",{staticClass:"hep-cr-output-content"},[e.activeTab==="stdout"?t("pre",[e._v(e._s(e.isRunning?"代码执行中...":e.output||'点击"运行"执行代码'))]):t("pre",{staticClass:"hep-cr-stderr"},[e._v(e._s(e.stderr))])])])])])},[],0,0,"e682487e").exports,re=G({name:"CodeRunnerDialog",components:{CodeRunner:L},props:{value:{type:Boolean,default:!1},title:{type:String,default:"代码执行器"},width:{type:[String,Number],default:800},language:{type:String,default:"javascript"},code:{type:String,default:""},pistonUrl:{type:String,default:"/api/piston"},theme:{type:String,default:"light"},themeColor:{type:String,default:""},showLanguageSelector:{type:Boolean,default:!0},showEditor:{type:Boolean,default:!0},editable:{type:Boolean,default:!0},executorLabel:{type:String,default:"运行"}},model:{prop:"value",event:"input"},data(){return{localVisible:this.value}},computed:{dialogWidth(){return typeof this.width=="number"?this.width+"px":this.width}},watch:{value(e){this.localVisible=e}},methods:{open(){this.localVisible=!0},close(){this.localVisible=!1,this.$emit("input",!1),this.$emit("update:value",!1),this.$emit("close")},handleOverlayClick(e){e.target===e.currentTarget&&this.close()}},expose:["open","close"]},function(){var e=this,t=e._self._c;return e.localVisible?t("div",{staticClass:"hep-cr-dialog-overlay",on:{click:e.handleOverlayClick}},[t("div",{staticClass:"hep-cr-dialog-container",style:{width:e.dialogWidth}},[t("div",{staticClass:"hep-cr-dialog-header"},[t("h3",{staticClass:"hep-cr-dialog-title"},[e._v(e._s(e.title))]),t("button",{staticClass:"hep-cr-dialog-close",on:{click:e.close}},[t("svg",{attrs:{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"}},[t("line",{attrs:{x1:"18",y1:"6",x2:"6",y2:"18"}}),t("line",{attrs:{x1:"6",y1:"6",x2:"18",y2:"18"}})])])]),t("div",{staticClass:"hep-cr-dialog-body"},[t("CodeRunner",e._g({attrs:{language:e.language,code:e.code,pistonUrl:e.pistonUrl,theme:e.theme,themeColor:e.themeColor,showLanguageSelector:e.showLanguageSelector,showEditor:e.showEditor,editable:e.editable,executorLabel:e.executorLabel},on:{"update:language":function(i){e.language=i},"update:code":function(i){e.code=i}}},e.$listeners))],1),t("div",{staticClass:"hep-cr-dialog-footer"},[e._t("footer",null,{close:e.close})],2)])]):e._e()},[],0,0,"bfc51494").exports;L.install=e=>{e.component("CodeRunner",L)};const ie={install(e){e.component("CodeRunner",L)}};exports.CodeRunner=L,exports.CodeRunnerDialog=re,exports.default=ie;
228
+ `;i&&i.remove();const p=document.createElement("style");p.id=t,p.textContent=c,document.head.appendChild(p)},escapeHtml:function(e){var t=document.createElement("div");return t.textContent=e,t.innerHTML},handleInput:function(e){this.$emit("input",e.target.value),this.$emit("update:value",e.target.value),this.emitChange(e.target.value)},handleScroll:function(e){var t=this.$refs.highlightRef;t&&(t.scrollTop=e.target.scrollTop,t.scrollLeft=e.target.scrollLeft)},handleKeydown:function(e){if(e.key==="Tab"){e.preventDefault();var t=e.target,i=t.selectionStart,c=t.selectionEnd,p=t.value;t.value=p.substring(0,i)+" "+p.substring(c),t.selectionStart=t.selectionEnd=i+2,this.$emit("input",t.value),this.$emit("update:value",t.value),this.emitChange(t.value)}},emitChange:function(e){var t=this;t.changeTimer&&clearTimeout(t.changeTimer),t.changeTimer=setTimeout(function(){t.$emit("change",e)},500)}},beforeDestroy:function(){this.changeTimer&&clearTimeout(this.changeTimer)}},function(){var e=this,t=e._self._c;return t("div",{staticClass:"hep-cr-editor",class:"hep-cr-theme-"+e.theme,style:{background:e.editorBackground}},[t("pre",{ref:"highlightRef",staticClass:"hep-cr-highlight",class:"language-"+e.prismLanguage,attrs:{"aria-hidden":"true"}},[t("code",{domProps:{innerHTML:e._s(e.highlightedCode)}})]),t("textarea",{staticClass:"hep-cr-input",attrs:{disabled:e.disabled,spellcheck:"false",placeholder:"请输入代码..."},domProps:{value:e.value},on:{input:e.handleInput,scroll:e.handleScroll,keydown:e.handleKeydown}})])},[],0,0,"c5a23c34").exports},props:{pistonUrl:{type:String,default:"/api/piston"},token:{type:String,default:""},language:{type:String,default:"javascript"},code:{type:String,default:""},theme:{type:String,default:"light",validator:function(e){return["light","dark"].indexOf(e)!==-1}},themeColor:{type:String,default:""},showLanguageSelector:{type:Boolean,default:!0},showEditor:{type:Boolean,default:!0},editable:{type:Boolean,default:!0},executorLabel:{type:String,default:"运行"}},data:function(){return{runtimes:[],isCodeModified:!1,internalLanguage:this.language||"javascript",internalCode:this.code!==void 0?this.code:"",currentTheme:this.theme,output:"",stderr:"",isRunning:!1,executionTime:null,activeTab:"stdout",error:null,runtimesLoading:!1,client:null,editorWidth:60,copiedEditor:!1,copiedOutput:!1}},computed:{themeClass:function(){return"hep-cr-runner-"+this.currentTheme},themeStyle:function(){if(!this.themeColor)return{};var e,t=this.currentTheme==="dark",i=this.themeColor,c=function(f,l){var b=parseInt(f.replace("#",""),16),h=Math.round(2.55*l);return"#"+(16777216+65536*Math.min(255,Math.max(0,(b>>16)+h))+256*Math.min(255,Math.max(0,(b>>8&255)+h))+Math.min(255,Math.max(0,(255&b)+h))).toString(16).slice(1)},p=(.299*((e=parseInt(i.replace("#",""),16))>>16&255)+.587*(e>>8&255)+.114*(255&e))/255>.5?"#000":"#fff";return{"--hep-cr-theme-color":i,"--hep-cr-theme-color-hover":c(i,t?20:-20),"--hep-cr-tab-active-color":p}},languageOptions:function(){return this.runtimes.map(function(e){return{value:e.language+":"+e.version,label:e.language.charAt(0).toUpperCase()+e.language.slice(1)+" "+e.version}})},languageName:function(){var e=this.internalLanguage;return e.includes(":")?e.split(":")[0]:e}},watch:{language:function(e){e&&e!==this.internalLanguage&&(this.internalLanguage=e)},code:function(e){e!==void 0&&e!==this.internalCode&&(this.internalCode=e)},language:function(e){e&&e!==this.internalLanguage&&(this.internalLanguage=e)},internalLanguage:function(e){this.isCodeModified||(this.internalCode=function(t){const i=t.toLowerCase().split(":")[0];return ne[i]||`// ${t}
229
+ // Write your code here`}(e)),this.isCodeModified=!1,this.$emit("update:language",e),this.$emit("language-change",e.includes(":")?e.split(":")[0]:e,this.internalCode)},internalCode:function(e){this.$emit("update:code",e),this.$emit("change",e)}},mounted:function(){this.client=new te({pistonUrl:this.pistonUrl,token:this.token}),this.loadRuntimes()},methods:{loadRuntimes:function(){var e=this;this.runtimesLoading=!0,this.error=null,this.client.getRuntimes().then(function(t){e.runtimes=t;var i=e.languageName,c=t.find(function(p){return p.language===i});c&&!e.internalLanguage.includes(":")&&(e.internalLanguage=i+":"+c.version)}).catch(function(t){e.error=t.message||"Failed to load runtimes"}).finally(function(){e.runtimesLoading=!1})},handleCodeInput:function(e){this.isCodeModified=!0,this.internalCode=e},handleCodeChange:function(e){this.internalCode=e},execute:function(){var e=this;this.isRunning||(this.isRunning=!0,this.output="",this.stderr="",this.executionTime=null,this.error=null,this.activeTab="stdout",this.$emit("execute-start"),this.client.execute(this.languageName,this.internalCode).then(function(t){e.output=t.output,e.stderr=t.stderr,e.executionTime=t.executionTime||null,e.activeTab=t.stderr?"stderr":"stdout",e.$emit("execute-end",t)}).catch(function(t){e.error=t.message||"Execution failed",e.$emit("execute-end",{success:!1,output:"",stderr:e.error,code:-1})}).finally(function(){e.isRunning=!1}))},clearOutput:function(){this.output="",this.stderr="",this.executionTime=null,this.error=null},copyCode:function(){var e=this;navigator.clipboard.writeText(this.internalCode),this.copiedEditor=!0,setTimeout(function(){e.copiedEditor=!1},2e3)},copyOutput:function(){var e=this,t=this.activeTab==="stdout"?this.output:this.stderr;navigator.clipboard.writeText(t),this.copiedOutput=!0,setTimeout(function(){e.copiedOutput=!1},2e3)},toggleTheme:function(){this.currentTheme=this.currentTheme==="light"?"dark":"light"},startDrag:function(e){var t=this,i=document.querySelector(".hep-cr-runner-main");if(i){var c=function(f){var l=i.getBoundingClientRect(),b=(f.clientX-l.left)/l.width*100;t.editorWidth=Math.max(20,Math.min(80,b))},p=function(){document.removeEventListener("mousemove",c),document.removeEventListener("mouseup",p),document.body.style.cursor="",document.body.style.userSelect=""};document.addEventListener("mousemove",c),document.addEventListener("mouseup",p),document.body.style.cursor="col-resize",document.body.style.userSelect="none"}}}},function(){var e=this,t=e._self._c;return t("div",{class:["hep-cr-runner",e.themeClass],style:e.themeStyle},[t("div",{staticClass:"hep-cr-runner-header"},[t("div",{staticClass:"hep-cr-runner-controls"},[e.showLanguageSelector?t("select",{directives:[{name:"model",rawName:"v-model",value:e.internalLanguage,expression:"internalLanguage"}],staticClass:"hep-cr-language-select",attrs:{disabled:e.isRunning},on:{change:function(i){var c=Array.prototype.filter.call(i.target.options,function(p){return p.selected}).map(function(p){return"_value"in p?p._value:p.value});e.internalLanguage=i.target.multiple?c:c[0]}}},[e.runtimesLoading?t("option",{attrs:{value:""}},[e._v("加载中...")]):e._e(),e._l(e.languageOptions,function(i){return t("option",{key:i.value,domProps:{value:i.value}},[e._v(" "+e._s(i.label)+" ")])})],2):e._e()]),t("div",{staticClass:"hep-cr-runner-actions"},[t("button",{staticClass:"hep-cr-btn hep-cr-btn-run",attrs:{disabled:e.isRunning||e.runtimesLoading},on:{click:e.execute}},[e.isRunning?t("span",{staticClass:"hep-cr-spinner"}):t("span",{staticClass:"hep-cr-run-icon"},[e._v("▶")]),e._v(" "+e._s(e.isRunning?"运行中...":e.executorLabel)+" ")]),t("button",{staticClass:"hep-cr-btn hep-cr-btn-theme",attrs:{title:e.currentTheme==="light"?"Switch to dark mode":"Switch to light mode"},on:{click:e.toggleTheme}},[e.currentTheme==="light"?t("svg",{attrs:{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"}},[t("path",{attrs:{d:"M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z"}})]):t("svg",{attrs:{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"}},[t("circle",{attrs:{cx:"12",cy:"12",r:"5"}}),t("line",{attrs:{x1:"12",y1:"1",x2:"12",y2:"3"}}),t("line",{attrs:{x1:"12",y1:"21",x2:"12",y2:"23"}}),t("line",{attrs:{x1:"4.22",y1:"4.22",x2:"5.64",y2:"5.64"}}),t("line",{attrs:{x1:"18.36",y1:"18.36",x2:"19.78",y2:"19.78"}}),t("line",{attrs:{x1:"1",y1:"12",x2:"3",y2:"12"}}),t("line",{attrs:{x1:"21",y1:"12",x2:"23",y2:"12"}}),t("line",{attrs:{x1:"4.22",y1:"19.78",x2:"5.64",y2:"18.36"}}),t("line",{attrs:{x1:"18.36",y1:"5.64",x2:"19.78",y2:"4.22"}})])])])]),e.error?t("div",{staticClass:"hep-cr-error-message"},[e._v(" "+e._s(e.error)+" ")]):e._e(),t("div",{staticClass:"hep-cr-runner-main"},[e.showEditor?t("div",{staticClass:"hep-cr-editor-panel",style:{width:e.editorWidth+"%"}},[t("div",{staticClass:"hep-cr-panel-header"},[t("span",{staticClass:"hep-cr-panel-title"},[e._v("编辑器")]),t("div",{staticClass:"hep-cr-output-actions"},[t("span",{staticClass:"hep-cr-language-badge"},[e._v(e._s(e.languageName))]),t("button",{staticClass:"hep-cr-btn-icon",class:{"hep-cr-btn-copied":e.copiedEditor},attrs:{disabled:e.copiedEditor,title:e.copiedEditor?"已复制":"复制"},on:{click:e.copyCode}},[e.copiedEditor?t("span",{staticClass:"hep-cr-copied-text"},[e._v("已复制")]):t("svg",{attrs:{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"}},[t("rect",{attrs:{x:"9",y:"9",width:"13",height:"13",rx:"2",ry:"2"}}),t("path",{attrs:{d:"M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"}})])])])]),t("CodeEditor",{attrs:{value:e.internalCode,language:e.languageName,theme:e.currentTheme,disabled:!e.editable||e.isRunning},on:{input:e.handleCodeInput,change:e.handleCodeChange}})],1):e._e(),e.showEditor?t("div",{staticClass:"hep-cr-resize-handle",on:{mousedown:e.startDrag}},[t("div",{staticClass:"hep-cr-resize-line"})]):e._e(),t("div",{staticClass:"hep-cr-output-panel",style:{width:e.showEditor?100-e.editorWidth+"%":"100%"}},[t("div",{staticClass:"hep-cr-panel-header"},[t("div",{staticClass:"hep-cr-output-tabs"},[t("button",{class:["hep-cr-tab",{active:e.activeTab==="stdout"}],on:{click:function(i){e.activeTab="stdout"}}},[e._v(" 输出 ")]),e.stderr?t("button",{class:["hep-cr-tab","hep-cr-tab-error",{active:e.activeTab==="stderr"}],on:{click:function(i){e.activeTab="stderr"}}},[e._v(" 错误 ")]):e._e()]),t("div",{staticClass:"hep-cr-output-actions"},[e.executionTime!==null?t("span",{staticClass:"hep-cr-execution-time"},[e._v(" "+e._s(e.executionTime)+"ms ")]):e._e(),t("button",{staticClass:"hep-cr-btn-icon",class:{"hep-cr-btn-copied":e.copiedOutput},attrs:{disabled:e.copiedOutput,title:e.copiedOutput?"已复制":"复制"},on:{click:e.copyOutput}},[e.copiedOutput?t("span",{staticClass:"hep-cr-copied-text"},[e._v("已复制")]):t("svg",{attrs:{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"}},[t("rect",{attrs:{x:"9",y:"9",width:"13",height:"13",rx:"2",ry:"2"}}),t("path",{attrs:{d:"M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"}})])])])]),t("div",{staticClass:"hep-cr-output-content"},[e.activeTab==="stdout"?t("pre",[e._v(e._s(e.isRunning?"代码执行中...":e.output||'点击"运行"执行代码'))]):t("pre",{staticClass:"hep-cr-stderr"},[e._v(e._s(e.stderr))])])])])])},[],0,0,"8e66fc6f").exports,re=z({name:"CodeRunnerDialog",components:{CodeRunner:L},props:{value:{type:Boolean,default:!1},title:{type:String,default:"代码执行器"},width:{type:[String,Number],default:800},language:{type:String,default:"javascript"},code:{type:String,default:""},pistonUrl:{type:String,default:"/api/piston"},token:{type:String,default:""},theme:{type:String,default:"light"},themeColor:{type:String,default:""},showLanguageSelector:{type:Boolean,default:!0},showEditor:{type:Boolean,default:!0},editable:{type:Boolean,default:!0},executorLabel:{type:String,default:"运行"}},model:{prop:"value",event:"input"},data(){return{localVisible:this.value}},computed:{dialogWidth(){return typeof this.width=="number"?this.width+"px":this.width}},watch:{value(e){this.localVisible=e}},methods:{open(){this.localVisible=!0},close(){this.localVisible=!1,this.$emit("input",!1),this.$emit("update:value",!1),this.$emit("close")},handleOverlayClick(e){e.target===e.currentTarget&&this.close()}},expose:["open","close"]},function(){var e=this,t=e._self._c;return e.localVisible?t("div",{staticClass:"hep-cr-dialog-overlay",on:{click:e.handleOverlayClick}},[t("div",{staticClass:"hep-cr-dialog-container",style:{width:e.dialogWidth}},[t("div",{staticClass:"hep-cr-dialog-header"},[t("h3",{staticClass:"hep-cr-dialog-title"},[e._v(e._s(e.title))]),t("button",{staticClass:"hep-cr-dialog-close",on:{click:e.close}},[t("svg",{attrs:{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"}},[t("line",{attrs:{x1:"18",y1:"6",x2:"6",y2:"18"}}),t("line",{attrs:{x1:"6",y1:"6",x2:"18",y2:"18"}})])])]),t("div",{staticClass:"hep-cr-dialog-body"},[t("CodeRunner",e._g({attrs:{language:e.language,code:e.code,pistonUrl:e.pistonUrl,token:e.token,theme:e.theme,themeColor:e.themeColor,showLanguageSelector:e.showLanguageSelector,showEditor:e.showEditor,editable:e.editable,executorLabel:e.executorLabel},on:{"update:language":function(i){e.language=i},"update:code":function(i){e.code=i}}},e.$listeners))],1),t("div",{staticClass:"hep-cr-dialog-footer"},[e._t("footer",null,{close:e.close})],2)])]):e._e()},[],0,0,"95644376").exports;L.install=e=>{e.component("CodeRunner",L)};const ie={install(e){e.component("CodeRunner",L)}};exports.CodeRunner=L,exports.CodeRunnerDialog=re,exports.default=ie;
package/dist/index.mjs CHANGED
@@ -1,16 +1,20 @@
1
- var ee = Object.defineProperty, Z = (e, t, i) => ((c, p, f) => p in c ? ee(c, p, { enumerable: !0, configurable: !0, writable: !0, value: f }) : c[p] = f)(e, typeof t != "symbol" ? t + "" : t, i);
2
- let H = null;
1
+ var ee = Object.defineProperty, B = (e, t, i) => ((c, p, f) => p in c ? ee(c, p, { enumerable: !0, configurable: !0, writable: !0, value: f }) : c[p] = f)(e, typeof t != "symbol" ? t + "" : t, i);
2
+ let j = null;
3
3
  class te {
4
4
  constructor(t = {}) {
5
- Z(this, "baseUrl"), Z(this, "timeout"), this.baseUrl = t.pistonUrl || "/api/piston", this.timeout = t.timeout || 3e3;
5
+ B(this, "baseUrl"), B(this, "timeout"), B(this, "token"), this.baseUrl = t.pistonUrl || "/api/piston", this.timeout = t.timeout || 3e3, this.token = t.token;
6
+ }
7
+ authHeaders() {
8
+ const t = { "Content-Type": "application/json" };
9
+ return this.token && (t.authorization = `Bearer ${this.token}`, t["id-token"] = this.token), t;
6
10
  }
7
11
  async getRuntimes(t = !1) {
8
- if (H && !t) return H;
12
+ if (j && !t) return j;
9
13
  try {
10
- const i = await fetch(`${this.baseUrl}/runtimes`, { method: "GET", headers: { "Content-Type": "application/json" } });
14
+ const i = await fetch(`${this.baseUrl}/runtimes`, { method: "GET", headers: this.authHeaders() });
11
15
  if (!i.ok) throw new Error(`Failed to fetch runtimes: ${i.statusText}`);
12
16
  const c = await i.json();
13
- return H = c, c;
17
+ return j = c, c;
14
18
  } catch (i) {
15
19
  throw i;
16
20
  }
@@ -23,7 +27,7 @@ class te {
23
27
  if (!p) throw new Error(`Language '${t}' is not supported`);
24
28
  const f = this.getFileName(t), l = { language: p.language, version: c.version || p.version, files: [{ name: f, content: i }], stdin: c.stdin || "", args: c.args || [], run_timeout: c.runTimeout || this.timeout, compile_timeout: this.timeout }, b = Date.now();
25
29
  try {
26
- const h = await fetch(`${this.baseUrl}/execute`, { method: "POST", headers: { "Content-Type": "application/json" }, body: JSON.stringify(l) });
30
+ const h = await fetch(`${this.baseUrl}/execute`, { method: "POST", headers: this.authHeaders(), body: JSON.stringify(l) });
27
31
  if (!h.ok) throw new Error(`Execute failed: ${h.statusText}`);
28
32
  const m = await h.json(), k = Date.now() - b, S = m.run.stdout || "", T = m.run.stderr || "";
29
33
  return { success: m.run.code === 0, output: S, stderr: T, code: m.run.code, executionTime: k, compile: m.compile ? { stdout: m.compile.stdout || "", stderr: m.compile.stderr || "", code: m.compile.code } : void 0 };
@@ -243,31 +247,31 @@ var V = { exports: {} };
243
247
  g = Array.isArray(g) ? g : [g];
244
248
  for (var E = 0; E < g.length; ++E) {
245
249
  if (d && d.cause == u + "," + E) return;
246
- var y = g[E], L = y.inside, z = !!y.lookbehind, W = !!y.greedy, q = y.alias;
247
- if (W && !y.pattern.global) {
250
+ var y = g[E], L = y.inside, W = !!y.lookbehind, Y = !!y.greedy, q = y.alias;
251
+ if (Y && !y.pattern.global) {
248
252
  var J = y.pattern.toString().match(/[imsuy]*$/)[0];
249
253
  y.pattern = RegExp(y.pattern.source, J + "g");
250
254
  }
251
- for (var Y = y.pattern || y, v = s.next, w = o; v !== n.tail && !(d && w >= d.reach); w += v.value.length, v = v.next) {
255
+ for (var X = y.pattern || y, v = s.next, w = o; v !== n.tail && !(d && w >= d.reach); w += v.value.length, v = v.next) {
252
256
  var R = v.value;
253
257
  if (n.length > a.length) return;
254
258
  if (!(R instanceof b)) {
255
259
  var x, O = 1;
256
- if (W) {
257
- if (!(x = h(Y, w, a, z)) || x.index >= a.length) break;
260
+ if (Y) {
261
+ if (!(x = h(X, w, a, W)) || x.index >= a.length) break;
258
262
  var N = x.index, Q = x.index + x[0].length, C = w;
259
263
  for (C += v.value.length; N >= C; ) C += (v = v.next).value.length;
260
264
  if (w = C -= v.value.length, v.value instanceof b) continue;
261
265
  for (var F = v; F !== n.tail && (C < Q || typeof F.value == "string"); F = F.next) O++, C += F.value.length;
262
266
  O--, R = a.slice(w, C), x.index -= w;
263
- } else if (!(x = h(Y, 0, R, z))) continue;
267
+ } else if (!(x = h(X, 0, R, W))) continue;
264
268
  N = x.index;
265
- var P = x[0], M = R.slice(0, N), X = R.slice(N + P.length), U = w + R.length;
269
+ var P = x[0], M = R.slice(0, N), Z = R.slice(N + P.length), U = w + R.length;
266
270
  d && U > d.reach && (d.reach = U);
267
271
  var D = v.prev;
268
- if (M && (D = S(n, D, M), w += M.length), T(n, D, O), v = S(n, D, new b(u, L ? l.tokenize(P, L) : P, q, P)), X && S(n, v, X), O > 1) {
269
- var B = { cause: u + "," + E, reach: U };
270
- m(a, n, r, v.prev, w, B), d && B.reach > d.reach && (d.reach = B.reach);
272
+ if (M && (D = S(n, D, M), w += M.length), T(n, D, O), v = S(n, D, new b(u, L ? l.tokenize(P, L) : P, q, P)), Z && S(n, v, Z), O > 1) {
273
+ var H = { cause: u + "," + E, reach: U };
274
+ m(a, n, r, v.prev, w, H), d && H.reach > d.reach && (d.reach = H.reach);
271
275
  }
272
276
  }
273
277
  }
@@ -384,7 +388,7 @@ var V = { exports: {} };
384
388
  }
385
389
  }();
386
390
  })(V);
387
- const j = ae(V.exports);
391
+ const G = ae(V.exports);
388
392
  Prism.languages.clike = { comment: [{ pattern: /(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/, lookbehind: !0, greedy: !0 }, { pattern: /(^|[^\\:])\/\/.*/, lookbehind: !0, greedy: !0 }], string: { pattern: /(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/, greedy: !0 }, "class-name": { pattern: /(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i, lookbehind: !0, inside: { punctuation: /[.\\]/ } }, keyword: /\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/, boolean: /\b(?:false|true)\b/, function: /\b\w+(?=\()/, number: /\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i, operator: /[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/, punctuation: /[{}[\];(),.:]/ }, Prism.languages.javascript = Prism.languages.extend("clike", { "class-name": [Prism.languages.clike["class-name"], { pattern: /(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/, lookbehind: !0 }], keyword: [{ pattern: /((?:^|\})\s*)catch\b/, lookbehind: !0 }, { pattern: /(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/, lookbehind: !0 }], function: /#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/, number: { pattern: RegExp(/(^|[^\w$])/.source + "(?:" + /NaN|Infinity/.source + "|" + /0[bB][01]+(?:_[01]+)*n?/.source + "|" + /0[oO][0-7]+(?:_[0-7]+)*n?/.source + "|" + /0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source + "|" + /\d+(?:_\d+)*n/.source + "|" + /(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source + ")" + /(?![\w$])/.source), lookbehind: !0 }, operator: /--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/ }), Prism.languages.javascript["class-name"][0].pattern = /(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/, Prism.languages.insertBefore("javascript", "keyword", { regex: { pattern: RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source + /\//.source + "(?:" + /(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source + "|" + /(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source + ")" + /(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source), lookbehind: !0, greedy: !0, inside: { "regex-source": { pattern: /^(\/)[\s\S]+(?=\/[a-z]*$)/, lookbehind: !0, alias: "language-regex", inside: Prism.languages.regex }, "regex-delimiter": /^\/|\/$/, "regex-flags": /^[a-z]+$/ } }, "function-variable": { pattern: /#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/, alias: "function" }, parameter: [{ pattern: /(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/, lookbehind: !0, inside: Prism.languages.javascript }, { pattern: /(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i, lookbehind: !0, inside: Prism.languages.javascript }, { pattern: /(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/, lookbehind: !0, inside: Prism.languages.javascript }, { pattern: /((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/, lookbehind: !0, inside: Prism.languages.javascript }], constant: /\b[A-Z](?:[A-Z_]|\dx?)*\b/ }), Prism.languages.insertBefore("javascript", "string", { hashbang: { pattern: /^#!.*/, greedy: !0, alias: "comment" }, "template-string": { pattern: /`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/, greedy: !0, inside: { "template-punctuation": { pattern: /^`|`$/, alias: "string" }, interpolation: { pattern: /((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/, lookbehind: !0, inside: { "interpolation-punctuation": { pattern: /^\$\{|\}$/, alias: "punctuation" }, rest: Prism.languages.javascript } }, string: /[\s\S]+/ } }, "string-property": { pattern: /((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m, lookbehind: !0, greedy: !0, alias: "property" } }), Prism.languages.insertBefore("javascript", "operator", { "literal-property": { pattern: /((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m, lookbehind: !0, alias: "property" } }), Prism.languages.markup && (Prism.languages.markup.tag.addInlined("script", "javascript"), Prism.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source, "javascript")), Prism.languages.js = Prism.languages.javascript, Prism.languages.python = { comment: { pattern: /(^|[^\\])#.*/, lookbehind: !0, greedy: !0 }, "string-interpolation": { pattern: /(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i, greedy: !0, inside: { interpolation: { pattern: /((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/, lookbehind: !0, inside: { "format-spec": { pattern: /(:)[^:(){}]+(?=\}$)/, lookbehind: !0 }, "conversion-option": { pattern: /![sra](?=[:}]$)/, alias: "punctuation" }, rest: null } }, string: /[\s\S]+/ } }, "triple-quoted-string": { pattern: /(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i, greedy: !0, alias: "string" }, string: { pattern: /(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i, greedy: !0 }, function: { pattern: /((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g, lookbehind: !0 }, "class-name": { pattern: /(\bclass\s+)\w+/i, lookbehind: !0 }, decorator: { pattern: /(^[\t ]*)@\w+(?:\.\w+)*/m, lookbehind: !0, alias: ["annotation", "punctuation"], inside: { punctuation: /\./ } }, keyword: /\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/, builtin: /\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/, boolean: /\b(?:False|None|True)\b/, number: /\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i, operator: /[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/, punctuation: /[{}[\];(),.:]/ }, Prism.languages.python["string-interpolation"].inside.interpolation.inside.rest = Prism.languages.python, Prism.languages.py = Prism.languages.python, Prism.languages.go = Prism.languages.extend("clike", { string: { pattern: /(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/, lookbehind: !0, greedy: !0 }, keyword: /\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/, boolean: /\b(?:_|false|iota|nil|true)\b/, number: [/\b0(?:b[01_]+|o[0-7_]+)i?\b/i, /\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i, /(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i], operator: /[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./, builtin: /\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/ }), Prism.languages.insertBefore("go", "string", { char: { pattern: /'(?:\\.|[^'\\\r\n]){0,10}'/, greedy: !0 } }), delete Prism.languages.go["class-name"], function(e) {
389
393
  var t = /\b(?:abstract|assert|boolean|break|byte|case|catch|char|class|const|continue|default|do|double|else|enum|exports|extends|final|finally|float|for|goto|if|implements|import|instanceof|int|interface|long|module|native|new|non-sealed|null|open|opens|package|permits|private|protected|provides|public|record(?!\s*[(){}[\]<>=%~.:,;?+\-*/&|^])|requires|return|sealed|short|static|strictfp|super|switch|synchronized|this|throw|throws|to|transient|transitive|try|uses|var|void|volatile|while|with|yield)\b/, i = /(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source, c = { pattern: RegExp(/(^|[^\w.])/.source + i + /[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source), lookbehind: !0, inside: { namespace: { pattern: /^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/, inside: { punctuation: /\./ } }, punctuation: /\./ } };
390
394
  e.languages.java = e.languages.extend("clike", { string: { pattern: /(^|[^\\])"(?:\\.|[^"\\\r\n])*"/, lookbehind: !0, greedy: !0 }, "class-name": [c, { pattern: RegExp(/(^|[^\w.])/.source + i + /[A-Z]\w*(?=\s+\w+\s*[;,=()]|\s*(?:\[[\s,]*\]\s*)?::\s*new\b)/.source), lookbehind: !0, inside: c.inside }, { pattern: RegExp(/(\b(?:class|enum|extends|implements|instanceof|interface|new|record|throws)\s+)/.source + i + /[A-Z]\w*\b/.source), lookbehind: !0, inside: c.inside }], keyword: t, function: [e.languages.clike.function, { pattern: /(::\s*)[a-z_]\w*/, lookbehind: !0 }], number: /\b0b[01][01_]*L?\b|\b0x(?:\.[\da-f_p+-]+|[\da-f_]+(?:\.[\da-f_p+-]+)?)\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfl]?/i, operator: { pattern: /(^|[^.])(?:<<=?|>>>?=?|->|--|\+\+|&&|\|\||::|[?:~]|[-+*/%&|^!=<>]=?)/m, lookbehind: !0 }, constant: /\b[A-Z][A-Z_\d]+\b/ }), e.languages.insertBefore("java", "string", { "triple-quoted-string": { pattern: /"""[ \t]*[\r\n](?:(?:"|"")?(?:\\.|[^"\\]))*"""/, greedy: !0, alias: "string" }, char: { pattern: /'(?:\\.|[^'\\\r\n]){1,6}'/, greedy: !0 } }), e.languages.insertBefore("java", "class-name", { annotation: { pattern: /(^|[^.])@\w+(?:\s*\.\s*\w+)*/, lookbehind: !0, alias: "punctuation" }, generics: { pattern: /<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&))*>)*>)*>)*>/, inside: { "class-name": c, keyword: t, punctuation: /[<>(),.:]/, operator: /[?&|]/ } }, import: [{ pattern: RegExp(/(\bimport\s+)/.source + i + /(?:[A-Z]\w*|\*)(?=\s*;)/.source), lookbehind: !0, inside: { namespace: c.inside.namespace, punctuation: /\./, operator: /\*/, "class-name": /\w+/ } }, { pattern: RegExp(/(\bimport\s+static\s+)/.source + i + /(?:\w+|\*)(?=\s*;)/.source), lookbehind: !0, alias: "static", inside: { namespace: c.inside.namespace, static: /\b\w+$/, punctuation: /\./, operator: /\*/, "class-name": /\w+/ } }], namespace: { pattern: RegExp(/(\b(?:exports|import(?:\s+static)?|module|open|opens|package|provides|requires|to|transitive|uses|with)\s+)(?!<keyword>)[a-z]\w*(?:\.[a-z]\w*)*\.?/.source.replace(/<keyword>/g, function() {
@@ -403,12 +407,12 @@ Prism.languages.clike = { comment: [{ pattern: /(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/
403
407
  for (var p = ["comment", "function-name", "for-or-select", "assign-left", "parameter", "string", "environment", "function", "keyword", "builtin", "boolean", "file-descriptor", "operator", "punctuation", "number"], f = c.variable[1].inside, l = 0; l < p.length; l++) f[p[l]] = e.languages.bash[p[l]];
404
408
  e.languages.sh = e.languages.bash, e.languages.shell = e.languages.bash;
405
409
  }(Prism), Prism.languages.json = { property: { pattern: /(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/, lookbehind: !0, greedy: !0 }, string: { pattern: /(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/, lookbehind: !0, greedy: !0 }, comment: { pattern: /\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/, greedy: !0 }, number: /-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i, punctuation: /[{}[\],]/, operator: /:/, boolean: /\b(?:false|true)\b/, null: { pattern: /\bnull\b/, alias: "keyword" } }, Prism.languages.webmanifest = Prism.languages.json;
406
- function G(e, t, i, c, p, f, l, b) {
410
+ function z(e, t, i, c, p, f, l, b) {
407
411
  var h = typeof e == "function" ? e.options : e;
408
412
  return t && (h.render = t, h.staticRenderFns = i, h._compiled = !0), f && (h._scopeId = "data-v-" + f), { exports: e, options: h };
409
413
  }
410
- typeof window < "u" && (window.Prism = j);
411
- const $ = G({ name: "CodeRunner", components: { CodeEditor: G({ name: "CodeEditor", props: { value: { type: String, default: "" }, language: { type: String, default: "javascript" }, theme: { type: String, default: "dark" }, disabled: { type: Boolean, default: !1 } }, data: function() {
414
+ typeof window < "u" && (window.Prism = G);
415
+ const $ = z({ name: "CodeRunner", components: { CodeEditor: z({ name: "CodeEditor", props: { value: { type: String, default: "" }, language: { type: String, default: "javascript" }, theme: { type: String, default: "dark" }, disabled: { type: Boolean, default: !1 } }, data: function() {
412
416
  return { highlightRef: null, changeTimer: null };
413
417
  }, mounted() {
414
418
  this.loadPrismTheme(this.theme);
@@ -422,8 +426,8 @@ const $ = G({ name: "CodeRunner", components: { CodeEditor: G({ name: "CodeEdito
422
426
  return this.theme === "dark" ? "#1e1e1e" : "#fafafa";
423
427
  }, highlightedCode: function() {
424
428
  try {
425
- var e = j.languages[this.prismLanguage];
426
- if (e) return j.highlight(this.value || "", e, this.prismLanguage);
429
+ var e = G.languages[this.prismLanguage];
430
+ if (e) return G.highlight(this.value || "", e, this.prismLanguage);
427
431
  } catch {
428
432
  }
429
433
  return this.escapeHtml(this.value || "");
@@ -617,7 +621,7 @@ const $ = G({ name: "CodeRunner", components: { CodeEditor: G({ name: "CodeEdito
617
621
  } }, function() {
618
622
  var e = this, t = e._self._c;
619
623
  return t("div", { staticClass: "hep-cr-editor", class: "hep-cr-theme-" + e.theme, style: { background: e.editorBackground } }, [t("pre", { ref: "highlightRef", staticClass: "hep-cr-highlight", class: "language-" + e.prismLanguage, attrs: { "aria-hidden": "true" } }, [t("code", { domProps: { innerHTML: e._s(e.highlightedCode) } })]), t("textarea", { staticClass: "hep-cr-input", attrs: { disabled: e.disabled, spellcheck: "false", placeholder: "请输入代码..." }, domProps: { value: e.value }, on: { input: e.handleInput, scroll: e.handleScroll, keydown: e.handleKeydown } })]);
620
- }, [], 0, 0, "c5a23c34").exports }, props: { pistonUrl: { type: String, default: "/api/piston" }, language: { type: String, default: "javascript" }, code: { type: String, default: "" }, theme: { type: String, default: "light", validator: function(e) {
624
+ }, [], 0, 0, "c5a23c34").exports }, props: { pistonUrl: { type: String, default: "/api/piston" }, token: { type: String, default: "" }, language: { type: String, default: "javascript" }, code: { type: String, default: "" }, theme: { type: String, default: "light", validator: function(e) {
621
625
  return ["light", "dark"].indexOf(e) !== -1;
622
626
  } }, themeColor: { type: String, default: "" }, showLanguageSelector: { type: Boolean, default: !0 }, showEditor: { type: Boolean, default: !0 }, editable: { type: Boolean, default: !0 }, executorLabel: { type: String, default: "运行" } }, data: function() {
623
627
  return { runtimes: [], isCodeModified: !1, internalLanguage: this.language || "javascript", internalCode: this.code !== void 0 ? this.code : "", currentTheme: this.theme, output: "", stderr: "", isRunning: !1, executionTime: null, activeTab: "stdout", error: null, runtimesLoading: !1, client: null, editorWidth: 60, copiedEditor: !1, copiedOutput: !1 };
@@ -645,14 +649,14 @@ const $ = G({ name: "CodeRunner", components: { CodeEditor: G({ name: "CodeEdito
645
649
  e && e !== this.internalLanguage && (this.internalLanguage = e);
646
650
  }, internalLanguage: function(e) {
647
651
  this.isCodeModified || (this.internalCode = function(t) {
648
- const i = t.toLowerCase();
652
+ const i = t.toLowerCase().split(":")[0];
649
653
  return ne[i] || `// ${t}
650
654
  // Write your code here`;
651
655
  }(e)), this.isCodeModified = !1, this.$emit("update:language", e), this.$emit("language-change", e.includes(":") ? e.split(":")[0] : e, this.internalCode);
652
656
  }, internalCode: function(e) {
653
657
  this.$emit("update:code", e), this.$emit("change", e);
654
658
  } }, mounted: function() {
655
- this.client = new te({ pistonUrl: this.pistonUrl }), this.loadRuntimes();
659
+ this.client = new te({ pistonUrl: this.pistonUrl, token: this.token }), this.loadRuntimes();
656
660
  }, methods: { loadRuntimes: function() {
657
661
  var e = this;
658
662
  this.runtimesLoading = !0, this.error = null, this.client.getRuntimes().then(function(t) {
@@ -720,7 +724,7 @@ const $ = G({ name: "CodeRunner", components: { CodeEditor: G({ name: "CodeEdito
720
724
  } } }, [e._v(" 输出 ")]), e.stderr ? t("button", { class: ["hep-cr-tab", "hep-cr-tab-error", { active: e.activeTab === "stderr" }], on: { click: function(i) {
721
725
  e.activeTab = "stderr";
722
726
  } } }, [e._v(" 错误 ")]) : e._e()]), t("div", { staticClass: "hep-cr-output-actions" }, [e.executionTime !== null ? t("span", { staticClass: "hep-cr-execution-time" }, [e._v(" " + e._s(e.executionTime) + "ms ")]) : e._e(), t("button", { staticClass: "hep-cr-btn-icon", class: { "hep-cr-btn-copied": e.copiedOutput }, attrs: { disabled: e.copiedOutput, title: e.copiedOutput ? "已复制" : "复制" }, on: { click: e.copyOutput } }, [e.copiedOutput ? t("span", { staticClass: "hep-cr-copied-text" }, [e._v("已复制")]) : t("svg", { attrs: { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", "stroke-width": "2" } }, [t("rect", { attrs: { x: "9", y: "9", width: "13", height: "13", rx: "2", ry: "2" } }), t("path", { attrs: { d: "M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1" } })])])])]), t("div", { staticClass: "hep-cr-output-content" }, [e.activeTab === "stdout" ? t("pre", [e._v(e._s(e.isRunning ? "代码执行中..." : e.output || '点击"运行"执行代码'))]) : t("pre", { staticClass: "hep-cr-stderr" }, [e._v(e._s(e.stderr))])])])])]);
723
- }, [], 0, 0, "e682487e").exports, re = G({ name: "CodeRunnerDialog", components: { CodeRunner: $ }, props: { value: { type: Boolean, default: !1 }, title: { type: String, default: "代码执行器" }, width: { type: [String, Number], default: 800 }, language: { type: String, default: "javascript" }, code: { type: String, default: "" }, pistonUrl: { type: String, default: "/api/piston" }, theme: { type: String, default: "light" }, themeColor: { type: String, default: "" }, showLanguageSelector: { type: Boolean, default: !0 }, showEditor: { type: Boolean, default: !0 }, editable: { type: Boolean, default: !0 }, executorLabel: { type: String, default: "运行" } }, model: { prop: "value", event: "input" }, data() {
727
+ }, [], 0, 0, "8e66fc6f").exports, re = z({ name: "CodeRunnerDialog", components: { CodeRunner: $ }, props: { value: { type: Boolean, default: !1 }, title: { type: String, default: "代码执行器" }, width: { type: [String, Number], default: 800 }, language: { type: String, default: "javascript" }, code: { type: String, default: "" }, pistonUrl: { type: String, default: "/api/piston" }, token: { type: String, default: "" }, theme: { type: String, default: "light" }, themeColor: { type: String, default: "" }, showLanguageSelector: { type: Boolean, default: !0 }, showEditor: { type: Boolean, default: !0 }, editable: { type: Boolean, default: !0 }, executorLabel: { type: String, default: "运行" } }, model: { prop: "value", event: "input" }, data() {
724
728
  return { localVisible: this.value };
725
729
  }, computed: { dialogWidth() {
726
730
  return typeof this.width == "number" ? this.width + "px" : this.width;
@@ -734,12 +738,12 @@ const $ = G({ name: "CodeRunner", components: { CodeEditor: G({ name: "CodeEdito
734
738
  e.target === e.currentTarget && this.close();
735
739
  } }, expose: ["open", "close"] }, function() {
736
740
  var e = this, t = e._self._c;
737
- return e.localVisible ? t("div", { staticClass: "hep-cr-dialog-overlay", on: { click: e.handleOverlayClick } }, [t("div", { staticClass: "hep-cr-dialog-container", style: { width: e.dialogWidth } }, [t("div", { staticClass: "hep-cr-dialog-header" }, [t("h3", { staticClass: "hep-cr-dialog-title" }, [e._v(e._s(e.title))]), t("button", { staticClass: "hep-cr-dialog-close", on: { click: e.close } }, [t("svg", { attrs: { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", "stroke-width": "2" } }, [t("line", { attrs: { x1: "18", y1: "6", x2: "6", y2: "18" } }), t("line", { attrs: { x1: "6", y1: "6", x2: "18", y2: "18" } })])])]), t("div", { staticClass: "hep-cr-dialog-body" }, [t("CodeRunner", e._g({ attrs: { language: e.language, code: e.code, pistonUrl: e.pistonUrl, theme: e.theme, themeColor: e.themeColor, showLanguageSelector: e.showLanguageSelector, showEditor: e.showEditor, editable: e.editable, executorLabel: e.executorLabel }, on: { "update:language": function(i) {
741
+ return e.localVisible ? t("div", { staticClass: "hep-cr-dialog-overlay", on: { click: e.handleOverlayClick } }, [t("div", { staticClass: "hep-cr-dialog-container", style: { width: e.dialogWidth } }, [t("div", { staticClass: "hep-cr-dialog-header" }, [t("h3", { staticClass: "hep-cr-dialog-title" }, [e._v(e._s(e.title))]), t("button", { staticClass: "hep-cr-dialog-close", on: { click: e.close } }, [t("svg", { attrs: { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", "stroke-width": "2" } }, [t("line", { attrs: { x1: "18", y1: "6", x2: "6", y2: "18" } }), t("line", { attrs: { x1: "6", y1: "6", x2: "18", y2: "18" } })])])]), t("div", { staticClass: "hep-cr-dialog-body" }, [t("CodeRunner", e._g({ attrs: { language: e.language, code: e.code, pistonUrl: e.pistonUrl, token: e.token, theme: e.theme, themeColor: e.themeColor, showLanguageSelector: e.showLanguageSelector, showEditor: e.showEditor, editable: e.editable, executorLabel: e.executorLabel }, on: { "update:language": function(i) {
738
742
  e.language = i;
739
743
  }, "update:code": function(i) {
740
744
  e.code = i;
741
745
  } } }, e.$listeners))], 1), t("div", { staticClass: "hep-cr-dialog-footer" }, [e._t("footer", null, { close: e.close })], 2)])]) : e._e();
742
- }, [], 0, 0, "bfc51494").exports;
746
+ }, [], 0, 0, "95644376").exports;
743
747
  $.install = (e) => {
744
748
  e.component("CodeRunner", $);
745
749
  };
package/dist/style.css CHANGED
@@ -1 +1 @@
1
- .hep-cr-editor[data-v-c5a23c34]{position:relative;flex:1;overflow:hidden}.hep-cr-highlight[data-v-c5a23c34],.hep-cr-input[data-v-c5a23c34]{position:absolute;top:0;left:0;width:100%;height:100%;padding:12px 16px;margin:0;border:none;font-family:SF Mono,Monaco,Menlo,Ubuntu Mono,monospace;font-size:14px;line-height:1.6;white-space:pre;overflow:auto}.hep-cr-highlight[data-v-c5a23c34]{pointer-events:none;z-index:1}.hep-cr-highlight.hep-cr-highlight[data-v-c5a23c34]{background:transparent!important}.hep-cr-highlight code[data-v-c5a23c34]{display:block;font-family:inherit;background:transparent!important}.hep-cr-input[data-v-c5a23c34]{position:relative;z-index:2;background:transparent;color:transparent;caret-color:#d4d4d4;resize:none;outline:none}.hep-cr-input[data-v-c5a23c34]:disabled{opacity:.7}.hep-cr-theme-light .hep-cr-input[data-v-c5a23c34]{caret-color:#333}.hep-cr-highlight pre[class*=language-][data-v-c5a23c34]{text-shadow:none}.hep-cr-runner[data-v-e682487e]{display:flex;flex-direction:column;border:1px solid #e0e0e0;border-radius:12px;overflow:hidden;font-family:SF Mono,Monaco,Menlo,Ubuntu Mono,monospace}.hep-cr-runner-light[data-v-e682487e]{background:#fff}.hep-cr-runner-dark[data-v-e682487e]{background:#1e1e1e;border-color:#333}.hep-cr-runner-header[data-v-e682487e]{display:flex;justify-content:space-between;align-items:center;padding:12px 16px;background:#252526;border-bottom:1px solid #333}.hep-cr-runner-light .hep-cr-runner-header[data-v-e682487e]{background:#f3f3f3;border-color:#e0e0e0}.hep-cr-runner-controls[data-v-e682487e]{display:flex;gap:8px}.hep-cr-language-select[data-v-e682487e]{padding:6px 12px;border:1px solid #444;border-radius:6px;background:#2d2d2d;color:#d4d4d4;font-size:13px;cursor:pointer;outline:none}.hep-cr-runner-light .hep-cr-language-select[data-v-e682487e]{background:#fff;color:#333;border-color:#ccc}.hep-cr-language-select[data-v-e682487e]:focus{border-color:#4fc3f7}.hep-cr-runner-actions[data-v-e682487e]{display:flex;gap:8px}.hep-cr-btn[data-v-e682487e]{padding:6px 16px;border:none;border-radius:6px;font-size:13px;font-weight:500;cursor:pointer;display:flex;align-items:center;gap:6px;transition:all .2s}.hep-cr-btn[data-v-e682487e]:disabled{opacity:.5;cursor:not-allowed}.hep-cr-btn-run[data-v-e682487e]{background:var(--hep-cr-theme-color, #4caf50);color:var(--hep-cr-tab-active-color, #fff);font-weight:600}.hep-cr-btn-run[data-v-e682487e]:hover:not(:disabled){background:var(--hep-cr-theme-color-hover, #43a047)}.hep-cr-btn-theme[data-v-e682487e]{background:transparent;color:#fdd835;padding:6px 10px;font-size:14px;line-height:1;height:auto;min-height:28px;display:flex;align-items:center;justify-content:center}.hep-cr-btn-theme svg[data-v-e682487e]{display:block;width:18px;height:18px}.hep-cr-runner-light .hep-cr-btn-theme[data-v-e682487e]{color:#f57c00}.hep-cr-btn-theme[data-v-e682487e]:hover{background:#ffffff1a;color:#fff}.hep-cr-runner-light .hep-cr-btn-theme[data-v-e682487e]:hover{background:#0000000d}.hep-cr-error-message[data-v-e682487e]{padding:10px 16px;background:#c62828;color:#fff;font-size:13px}.hep-cr-runner-main[data-v-e682487e]{display:flex;height:400px;overflow:hidden}.hep-cr-editor-panel[data-v-e682487e]{display:flex;flex-direction:column;min-width:20%;max-width:80%}.hep-cr-panel-header[data-v-e682487e]{display:flex;justify-content:space-between;align-items:center;padding:8px 12px;background:#2d2d2d;border-bottom:1px solid #333}.hep-cr-runner-light .hep-cr-panel-header[data-v-e682487e]{background:#f0f0f0;border-color:#e0e0e0}.hep-cr-panel-title[data-v-e682487e]{font-size:12px;font-weight:600;color:#888;text-transform:uppercase;letter-spacing:.5px}.hep-cr-language-badge[data-v-e682487e]{font-size:11px;padding:2px 8px;background:var(--hep-cr-theme-color, #4fc3f7);color:var(--hep-cr-tab-active-color, #000);border-radius:10px;font-weight:600}.hep-cr-editor[data-v-e682487e]{flex:1;width:100%;background:#1e1e1e}.hep-cr-editor .hep-cr-highlight[data-v-e682487e]{background:transparent!important}.hep-cr-editor .hep-cr-input[data-v-e682487e]{color:transparent!important;caret-color:#d4d4d4}.hep-cr-runner-light .hep-cr-editor[data-v-e682487e]{background:#fafafa}.hep-cr-runner-light .hep-cr-editor .hep-cr-highlight code[data-v-e682487e]{color:#333}.hep-cr-resize-handle[data-v-e682487e]{width:8px;background:#2d2d2d;cursor:col-resize;display:flex;align-items:center;justify-content:center;transition:background .2s;border-left:1px solid #3d3d3d;border-right:1px solid #3d3d3d}.hep-cr-resize-handle[data-v-e682487e]:hover{background:var(--hep-cr-theme-color, #4fc3f7)}.hep-cr-resize-line[data-v-e682487e]{width:3px;height:40px;background:#555;border-radius:2px;transition:background .2s}.hep-cr-resize-handle:hover .hep-cr-resize-line[data-v-e682487e]{background:#fff}.hep-cr-runner-light .hep-cr-resize-handle[data-v-e682487e]{background:#e0e0e0;border-color:#ccc}.hep-cr-runner-light .hep-cr-resize-line[data-v-e682487e]{background:#bbb}.hep-cr-runner-light .hep-cr-resize-handle[data-v-e682487e]:hover{background:var(--hep-cr-theme-color, #4fc3f7)}.hep-cr-runner-light .hep-cr-resize-handle:hover .hep-cr-resize-line[data-v-e682487e]{background:#fff}.hep-cr-output-panel[data-v-e682487e]{display:flex;flex-direction:column;min-width:20%;border-left:1px solid #333}.hep-cr-runner-light .hep-cr-output-panel[data-v-e682487e]{border-color:#e0e0e0}.hep-cr-output-tabs[data-v-e682487e]{display:flex;gap:4px}.hep-cr-tab[data-v-e682487e]{padding:4px 12px;border:none;background:transparent;cursor:pointer;font-size:12px;border-radius:4px;color:#888;transition:all .2s}.hep-cr-tab[data-v-e682487e]:hover{color:#d4d4d4;background:#3d3d3d}.hep-cr-runner-light .hep-cr-tab[data-v-e682487e]:hover{color:#333;background:#e0e0e0}.hep-cr-tab.active[data-v-e682487e]{background:var(--hep-cr-theme-color, #4fc3f7);color:var(--hep-cr-tab-active-color, #000);font-weight:600}.hep-cr-tab-error.active[data-v-e682487e]{background:#f44336;color:#fff}.hep-cr-output-actions[data-v-e682487e]{display:flex;align-items:center;gap:12px}.hep-cr-execution-time[data-v-e682487e]{font-size:12px;color:var(--hep-cr-theme-color, #4caf50);font-weight:500}.hep-cr-btn-icon[data-v-e682487e]{background:transparent;border:none;cursor:pointer;padding:4px;border-radius:4px;color:#888;display:flex;align-items:center;justify-content:center;transition:all .2s}.hep-cr-btn-icon[data-v-e682487e]:hover{color:#fff;background:#3d3d3d}.hep-cr-runner-light .hep-cr-btn-icon[data-v-e682487e]:hover{color:#333;background:#e0e0e0}.hep-cr-btn-icon[data-v-e682487e]:disabled{cursor:not-allowed;opacity:.7}.hep-cr-btn-copied[data-v-e682487e]{color:#4caf50!important}.hep-cr-copied-text[data-v-e682487e]{font-size:12px;color:#4caf50}.hep-cr-output-content[data-v-e682487e]{flex:1;padding:12px 16px;overflow:auto;background:#1e1e1e}.hep-cr-runner-light .hep-cr-output-content[data-v-e682487e]{background:#fff}.hep-cr-output-content pre[data-v-e682487e]{margin:0;font-size:13px;line-height:1.6;white-space:pre-wrap;word-break:break-all;color:#d4d4d4}.hep-cr-runner-light .hep-cr-output-content pre[data-v-e682487e]{color:#333}.hep-cr-output-content .hep-cr-stderr[data-v-e682487e]{color:#f44336}.hep-cr-spinner[data-v-e682487e]{width:12px;height:12px;border:2px solid rgba(255,255,255,.3);border-top-color:#fff;border-radius:50%;animation:spin-e682487e .8s linear infinite}@keyframes spin-e682487e{to{transform:rotate(360deg)}}.hep-cr-dialog-overlay[data-v-bfc51494]{position:fixed;top:0;left:0;right:0;bottom:0;background:#00000080;display:flex;align-items:center;justify-content:center;z-index:9999}.hep-cr-dialog-container[data-v-bfc51494]{background:#fff;border-radius:12px;box-shadow:0 20px 60px #0000004d;max-width:90vw;max-height:90vh;display:flex;flex-direction:column;overflow:hidden}.hep-cr-dialog-header[data-v-bfc51494]{display:flex;align-items:center;justify-content:space-between;padding:16px 20px;border-bottom:1px solid #e0e0e0}.hep-cr-dialog-title[data-v-bfc51494]{margin:0;font-size:16px;font-weight:600;color:#333}.hep-cr-dialog-close[data-v-bfc51494]{background:none;border:none;cursor:pointer;padding:4px;border-radius:4px;color:#666;display:flex;align-items:center;justify-content:center;transition:all .2s}.hep-cr-dialog-close[data-v-bfc51494]:hover{background:#f0f0f0;color:#333}.hep-cr-dialog-body[data-v-bfc51494]{flex:1;overflow:auto;padding:0}.hep-cr-dialog-body[data-v-bfc51494] .hep-cr-runner{border:none;border-radius:0}.hep-cr-dialog-footer[data-v-bfc51494]{padding:12px 20px;border-top:1px solid #e0e0e0;display:flex;justify-content:flex-end;gap:12px}.hep-cr-dialog-fade-enter-active[data-v-bfc51494],.hep-cr-dialog-fade-leave-active[data-v-bfc51494]{transition:opacity .2s ease}.hep-cr-dialog-fade-enter-from[data-v-bfc51494],.hep-cr-dialog-fade-leave-to[data-v-bfc51494]{opacity:0}.hep-cr-dialog-fade-enter-active .hep-cr-dialog-container[data-v-bfc51494],.hep-cr-dialog-fade-leave-active .hep-cr-dialog-container[data-v-bfc51494]{transition:transform .2s ease}.hep-cr-dialog-fade-enter-from .hep-cr-dialog-container[data-v-bfc51494],.hep-cr-dialog-fade-leave-to .hep-cr-dialog-container[data-v-bfc51494]{transform:scale(.95)}
1
+ .hep-cr-editor[data-v-c5a23c34]{position:relative;flex:1;overflow:hidden}.hep-cr-highlight[data-v-c5a23c34],.hep-cr-input[data-v-c5a23c34]{position:absolute;top:0;left:0;width:100%;height:100%;padding:12px 16px;margin:0;border:none;font-family:SF Mono,Monaco,Menlo,Ubuntu Mono,monospace;font-size:14px;line-height:1.6;white-space:pre;overflow:auto}.hep-cr-highlight[data-v-c5a23c34]{pointer-events:none;z-index:1}.hep-cr-highlight.hep-cr-highlight[data-v-c5a23c34]{background:transparent!important}.hep-cr-highlight code[data-v-c5a23c34]{display:block;font-family:inherit;background:transparent!important}.hep-cr-input[data-v-c5a23c34]{position:relative;z-index:2;background:transparent;color:transparent;caret-color:#d4d4d4;resize:none;outline:none}.hep-cr-input[data-v-c5a23c34]:disabled{opacity:.7}.hep-cr-theme-light .hep-cr-input[data-v-c5a23c34]{caret-color:#333}.hep-cr-highlight pre[class*=language-][data-v-c5a23c34]{text-shadow:none}.hep-cr-runner[data-v-8e66fc6f]{display:flex;flex-direction:column;border:1px solid #e0e0e0;border-radius:12px;overflow:hidden;font-family:SF Mono,Monaco,Menlo,Ubuntu Mono,monospace}.hep-cr-runner-light[data-v-8e66fc6f]{background:#fff}.hep-cr-runner-dark[data-v-8e66fc6f]{background:#1e1e1e;border-color:#333}.hep-cr-runner-header[data-v-8e66fc6f]{display:flex;justify-content:space-between;align-items:center;padding:12px 16px;background:#252526;border-bottom:1px solid #333}.hep-cr-runner-light .hep-cr-runner-header[data-v-8e66fc6f]{background:#f3f3f3;border-color:#e0e0e0}.hep-cr-runner-controls[data-v-8e66fc6f]{display:flex;gap:8px}.hep-cr-language-select[data-v-8e66fc6f]{padding:6px 12px;border:1px solid #444;border-radius:6px;background:#2d2d2d;color:#d4d4d4;font-size:13px;cursor:pointer;outline:none}.hep-cr-runner-light .hep-cr-language-select[data-v-8e66fc6f]{background:#fff;color:#333;border-color:#ccc}.hep-cr-language-select[data-v-8e66fc6f]:focus{border-color:#4fc3f7}.hep-cr-runner-actions[data-v-8e66fc6f]{display:flex;gap:8px}.hep-cr-btn[data-v-8e66fc6f]{padding:6px 16px;border:none;border-radius:6px;font-size:13px;font-weight:500;cursor:pointer;display:flex;align-items:center;gap:6px;transition:all .2s}.hep-cr-btn[data-v-8e66fc6f]:disabled{opacity:.5;cursor:not-allowed}.hep-cr-btn-run[data-v-8e66fc6f]{background:var(--hep-cr-theme-color, #4caf50);color:var(--hep-cr-tab-active-color, #fff);font-weight:600}.hep-cr-btn-run[data-v-8e66fc6f]:hover:not(:disabled){background:var(--hep-cr-theme-color-hover, #43a047)}.hep-cr-btn-theme[data-v-8e66fc6f]{background:transparent;color:#fdd835;padding:6px 10px;font-size:14px;line-height:1;height:auto;min-height:28px;display:flex;align-items:center;justify-content:center}.hep-cr-btn-theme svg[data-v-8e66fc6f]{display:block;width:18px;height:18px}.hep-cr-runner-light .hep-cr-btn-theme[data-v-8e66fc6f]{color:#f57c00}.hep-cr-btn-theme[data-v-8e66fc6f]:hover{background:#ffffff1a;color:#fff}.hep-cr-runner-light .hep-cr-btn-theme[data-v-8e66fc6f]:hover{background:#0000000d}.hep-cr-error-message[data-v-8e66fc6f]{padding:10px 16px;background:#c62828;color:#fff;font-size:13px}.hep-cr-runner-main[data-v-8e66fc6f]{display:flex;height:400px;overflow:hidden}.hep-cr-editor-panel[data-v-8e66fc6f]{display:flex;flex-direction:column;min-width:20%;max-width:80%}.hep-cr-panel-header[data-v-8e66fc6f]{display:flex;justify-content:space-between;align-items:center;padding:8px 12px;background:#2d2d2d;border-bottom:1px solid #333}.hep-cr-runner-light .hep-cr-panel-header[data-v-8e66fc6f]{background:#f0f0f0;border-color:#e0e0e0}.hep-cr-panel-title[data-v-8e66fc6f]{font-size:12px;font-weight:600;color:#888;text-transform:uppercase;letter-spacing:.5px}.hep-cr-language-badge[data-v-8e66fc6f]{font-size:11px;padding:2px 8px;background:var(--hep-cr-theme-color, #4fc3f7);color:var(--hep-cr-tab-active-color, #000);border-radius:10px;font-weight:600}.hep-cr-editor[data-v-8e66fc6f]{flex:1;width:100%;background:#1e1e1e}.hep-cr-editor .hep-cr-highlight[data-v-8e66fc6f]{background:transparent!important}.hep-cr-editor .hep-cr-input[data-v-8e66fc6f]{color:transparent!important;caret-color:#d4d4d4}.hep-cr-runner-light .hep-cr-editor[data-v-8e66fc6f]{background:#fafafa}.hep-cr-runner-light .hep-cr-editor .hep-cr-highlight code[data-v-8e66fc6f]{color:#333}.hep-cr-resize-handle[data-v-8e66fc6f]{width:8px;background:#2d2d2d;cursor:col-resize;display:flex;align-items:center;justify-content:center;transition:background .2s;border-left:1px solid #3d3d3d;border-right:1px solid #3d3d3d}.hep-cr-resize-handle[data-v-8e66fc6f]:hover{background:var(--hep-cr-theme-color, #4fc3f7)}.hep-cr-resize-line[data-v-8e66fc6f]{width:3px;height:40px;background:#555;border-radius:2px;transition:background .2s}.hep-cr-resize-handle:hover .hep-cr-resize-line[data-v-8e66fc6f]{background:#fff}.hep-cr-runner-light .hep-cr-resize-handle[data-v-8e66fc6f]{background:#e0e0e0;border-color:#ccc}.hep-cr-runner-light .hep-cr-resize-line[data-v-8e66fc6f]{background:#bbb}.hep-cr-runner-light .hep-cr-resize-handle[data-v-8e66fc6f]:hover{background:var(--hep-cr-theme-color, #4fc3f7)}.hep-cr-runner-light .hep-cr-resize-handle:hover .hep-cr-resize-line[data-v-8e66fc6f]{background:#fff}.hep-cr-output-panel[data-v-8e66fc6f]{display:flex;flex-direction:column;min-width:20%;border-left:1px solid #333}.hep-cr-runner-light .hep-cr-output-panel[data-v-8e66fc6f]{border-color:#e0e0e0}.hep-cr-output-tabs[data-v-8e66fc6f]{display:flex;gap:4px}.hep-cr-tab[data-v-8e66fc6f]{padding:4px 12px;border:none;background:transparent;cursor:pointer;font-size:12px;border-radius:4px;color:#888;transition:all .2s}.hep-cr-tab[data-v-8e66fc6f]:hover{color:#d4d4d4;background:#3d3d3d}.hep-cr-runner-light .hep-cr-tab[data-v-8e66fc6f]:hover{color:#333;background:#e0e0e0}.hep-cr-tab.active[data-v-8e66fc6f]{background:var(--hep-cr-theme-color, #4fc3f7);color:var(--hep-cr-tab-active-color, #000);font-weight:600}.hep-cr-tab-error.active[data-v-8e66fc6f]{background:#f44336;color:#fff}.hep-cr-output-actions[data-v-8e66fc6f]{display:flex;align-items:center;gap:12px}.hep-cr-execution-time[data-v-8e66fc6f]{font-size:12px;color:var(--hep-cr-theme-color, #4caf50);font-weight:500}.hep-cr-btn-icon[data-v-8e66fc6f]{background:transparent;border:none;cursor:pointer;padding:4px;border-radius:4px;color:#888;display:flex;align-items:center;justify-content:center;transition:all .2s}.hep-cr-btn-icon[data-v-8e66fc6f]:hover{color:#fff;background:#3d3d3d}.hep-cr-runner-light .hep-cr-btn-icon[data-v-8e66fc6f]:hover{color:#333;background:#e0e0e0}.hep-cr-btn-icon[data-v-8e66fc6f]:disabled{cursor:not-allowed;opacity:.7}.hep-cr-btn-copied[data-v-8e66fc6f]{color:#4caf50!important}.hep-cr-copied-text[data-v-8e66fc6f]{font-size:12px;color:#4caf50}.hep-cr-output-content[data-v-8e66fc6f]{flex:1;padding:12px 16px;overflow:auto;background:#1e1e1e}.hep-cr-runner-light .hep-cr-output-content[data-v-8e66fc6f]{background:#fff}.hep-cr-output-content pre[data-v-8e66fc6f]{margin:0;font-size:13px;line-height:1.6;white-space:pre-wrap;word-break:break-all;color:#d4d4d4}.hep-cr-runner-light .hep-cr-output-content pre[data-v-8e66fc6f]{color:#333}.hep-cr-output-content .hep-cr-stderr[data-v-8e66fc6f]{color:#f44336}.hep-cr-spinner[data-v-8e66fc6f]{width:12px;height:12px;border:2px solid rgba(255,255,255,.3);border-top-color:#fff;border-radius:50%;animation:spin-8e66fc6f .8s linear infinite}@keyframes spin-8e66fc6f{to{transform:rotate(360deg)}}.hep-cr-dialog-overlay[data-v-95644376]{position:fixed;top:0;left:0;right:0;bottom:0;background:#00000080;display:flex;align-items:center;justify-content:center;z-index:9999}.hep-cr-dialog-container[data-v-95644376]{background:#fff;border-radius:12px;box-shadow:0 20px 60px #0000004d;max-width:90vw;max-height:90vh;display:flex;flex-direction:column;overflow:hidden}.hep-cr-dialog-header[data-v-95644376]{display:flex;align-items:center;justify-content:space-between;padding:16px 20px;border-bottom:1px solid #e0e0e0}.hep-cr-dialog-title[data-v-95644376]{margin:0;font-size:16px;font-weight:600;color:#333}.hep-cr-dialog-close[data-v-95644376]{background:none;border:none;cursor:pointer;padding:4px;border-radius:4px;color:#666;display:flex;align-items:center;justify-content:center;transition:all .2s}.hep-cr-dialog-close[data-v-95644376]:hover{background:#f0f0f0;color:#333}.hep-cr-dialog-body[data-v-95644376]{flex:1;overflow:auto;padding:0}.hep-cr-dialog-body[data-v-95644376] .hep-cr-runner{border:none;border-radius:0}.hep-cr-dialog-footer[data-v-95644376]{padding:12px 20px;border-top:1px solid #e0e0e0;display:flex;justify-content:flex-end;gap:12px}.hep-cr-dialog-fade-enter-active[data-v-95644376],.hep-cr-dialog-fade-leave-active[data-v-95644376]{transition:opacity .2s ease}.hep-cr-dialog-fade-enter-from[data-v-95644376],.hep-cr-dialog-fade-leave-to[data-v-95644376]{opacity:0}.hep-cr-dialog-fade-enter-active .hep-cr-dialog-container[data-v-95644376],.hep-cr-dialog-fade-leave-active .hep-cr-dialog-container[data-v-95644376]{transition:transform .2s ease}.hep-cr-dialog-fade-enter-from .hep-cr-dialog-container[data-v-95644376],.hep-cr-dialog-fade-leave-to .hep-cr-dialog-container[data-v-95644376]{transform:scale(.95)}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hep-code-runner/vue2",
3
- "version": "2.3.6",
3
+ "version": "2.3.7",
4
4
  "description": "Vue 2 code runner component",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",
@@ -24,7 +24,6 @@
24
24
  "vue": "^2.6.0 || ^2.7.0"
25
25
  },
26
26
  "devDependencies": {
27
- "@hep-code-runner/core": "workspace:*",
28
27
  "@types/prismjs": "^1.26.6",
29
28
  "@vitejs/plugin-vue2": "^2.3.1",
30
29
  "terser": "^5.46.1",
@@ -34,7 +33,7 @@
34
33
  "vue": "^2.7.16"
35
34
  },
36
35
  "dependencies": {
37
- "@hep-code-runner/core": "^1.0.0",
36
+ "@hep-code-runner/core": "workspace:*",
38
37
  "prismjs": "^1.30.0"
39
38
  }
40
39
  }